๐ฆ My Rust CMS
A full-stack content management system built entirely in Rust, featuring a sophisticated visual page builder with live edit mode and professional-grade customization. Built with the RAYDT Stack (Rust โข Axum โข Yew โข Diesel โข Tower) for maximum performance, safety, and developer productivity.
๐ฏ Overview
A professional, production-ready content management system built entirely in Rust. Features an advanced visual page builder with live edit mode, gradient backgrounds, shape masks, and comprehensive customization options. Comes pre-configured with professional styling and sample content.
๐ธ See it in action: Check out the Screenshots below to explore the CMS interface and features.
๐ What Makes This Special
๐จ Live Edit Mode
- Real-time visual editing with instant preview
- Multi-property change support with persistent state
- Gradient backgrounds, shape masks, and scroll effects
- Professional header templates with shrink animations
๐ Performance
- WebAssembly frontend for near-native browser performance
- Rust backend with zero-copy serialization
- Optimized component rendering with minimal re-renders
- Production-ready Docker deployment
๐ก๏ธ Security & Safety
- Memory safety through Rust's ownership system
- Type safety across the entire stack
- Secure session-based authentication
- Input sanitization and XSS protection
๐ฏ Production Ready
- Complete default data setup with professional styling
- Comprehensive error handling and logging
- Docker-based deployment with health checks
- Clean codebase with zero compiler warnings
๐ธ Screenshots
Get a visual preview of the CMS in action:
๐ Public Frontend
Modern, responsive public interface with gradient headers, shape masks, and professional styling
๐จ Visual Page Builder
Drag-and-drop page builder with live preview, component library, and real-time editing
๐๏ธ Template Manager
Advanced template management with live edit mode, gradient backgrounds, and scroll effects
๐ Content Management
Comprehensive post management with rich text editing and category organization
๐งญ Navigation Manager
Intuitive navigation management with drag-and-drop ordering and menu customization
๐ฅ User Management
Role-based user management with secure authentication and permission controls
๐ฌ Comment Moderation
Built-in comment system with moderation tools and user interaction management
โจ Features
๐จ Live Edit Mode
Professional visual editing system with real-time preview:
-
๐๏ธ Multi-Property Editing:
- Change height, colors, gradients, and effects simultaneously
- Persistent state management prevents data loss
- Context-aware property changes preserve existing styling
-
๐ Visual Effects:
- Gradient backgrounds with live preview
- Shape masks (tilt, wave, zigzag) with real-time updates
- Scroll effects with smooth animations
- Site title color customization
-
โ๏ธ Advanced Controls:
- Header height adjustment with proper constraints
- Navigation styling with hover effects
- Button customization with theme integration
- Typography system with live preview
๐๏ธ Page Builder
Sophisticated visual page builder with advanced component management:
-
๐งฉ Nested Architecture:
- Recursive component nesting with unlimited depth
- Container, TwoColumn, and ThreeColumn layout components
- Intuitive drag-and-drop interface
- Visual selection indicators with clear hierarchy
-
โ๏ธ Component Management:
- Hero, Text, Image, Gallery, and custom components
- Real-time property editing with live preview
- Component-specific styling and animations
- Responsive design controls
-
๐จ Design System:
- Professional gradient backgrounds
- Shape mask effects for modern design
- Typography system with custom fonts
- Admin dashboard with crab emoji branding
๐๏ธ Database & Content
Production-grade PostgreSQL with comprehensive schema:
- ๐ Content Management: Posts, pages, categories with rich metadata
- ๐งฉ Component Templates: 8 pre-configured templates with professional styling
- โ๏ธ Settings System: 47+ configuration options for complete customization
- ๐ฅ User Management: Role-based access with secure authentication
- ๐ง Default Data: Complete setup with sample content and professional styling
๐ Quick Start
๐ก New to the CMS? Check out the Screenshots section above to see the CMS in action before diving in!
๐ณ Docker Setup (Recommended)
The easiest way to get started is using Docker with our pre-configured setup:
Prerequisites
- Docker & Docker Compose: Install Docker
- Git: For cloning the repository
Installation
-
Clone the repository:
git clone https://github.com/yourusername/my_rust_cms.git cd my_rust_cms -
Start the entire stack:
# Start all services (database, backend, frontend) docker-compose up -d # Or use the development script ./dev-start.sh
-
Access your CMS:
- Frontend: http://localhost:8080
- Backend API: http://localhost:8081
- Admin Panel: http://localhost:8080/admin
-
Login credentials:
- Username:
admin - Password:
admin
- Username:
What You Get Out of the Box
- ๐จ Professional Header: Gradient background with tilt mask and shrink effects
- ๐ Sample Content: 4 blog posts and structured pages
- โ๏ธ Complete Configuration: 47 settings including typography and design system
- ๐ ๏ธ Live Edit Mode: Fully functional with all improvements
- ๐ฆ Admin Dashboard: Modern interface with crab emoji branding
๐ ๏ธ Local Development Setup
For development with hot reloading and debugging:
Prerequisites
- Rust (latest stable): Install from rustup.rs
- Trunk:
cargo install trunk - PostgreSQL (13+): Install PostgreSQL
- Diesel CLI:
cargo install diesel_cli --features postgres
Setup
-
Environment Configuration:
# Copy Docker environment as template cp docker.env .env # Update database URL for local development # Change: postgres://user:pass@postgres:5432/db # To: postgres://user:pass@localhost:5432/db
-
Database Setup:
# Start PostgreSQL (via Docker for convenience) docker-compose up -d postgres # Run migrations cd backend diesel setup diesel migration run
-
Start Development Servers:
# Terminal 1: Backend cd backend cargo run # Terminal 2: Frontend cd frontend trunk serve --release # Use --release for complex builds
๐จ Using the CMS
Live Edit Mode
- Navigate to your site: http://localhost:8080
- Enable Live Edit: Click the "๐จ Live Edit Mode" button (visible when logged in)
- Edit Components: Click any component to open the properties panel
- Customize: Adjust height, colors, gradients, effects in real-time
- Save Changes: Click "Save Changes" to persist your customizations
Admin Dashboard
- Access Admin: http://localhost:8080/admin
- Login: Use
admin/admincredentials - Manage Content: Create posts, pages, and manage site settings
- Design System: Customize typography, colors, and layout
- Templates: Manage header, footer, and component templates
Page Builder
- Edit Pages: Go to Admin > Pages > Edit
- Add Components: Drag components from the sidebar
- Nested Layouts: Use Container, TwoColumn, ThreeColumn components
- Style Components: Click components to edit properties
- Preview: Real-time preview with responsive design
๐ง Configuration
Default Setup
Your CMS comes pre-configured with:
- Header Template: Fixed header with gradient background (#667eea to #764ba2)
- Shape Effects: Lower tilt mask for modern design
- Typography: Pixelify Sans font family with optimized sizing
- Navigation: Responsive header navigation with hover effects
- Content: Professional sample posts and hero sections
Customization Options
- 47+ Settings: Complete control over typography, colors, layout
- 8 Component Templates: Headers, footers, containers, modals
- Design System: Integrated color schemes and typography
- Live Edit: Real-time visual customization
- Responsive Design: Mobile-first approach with breakpoint controls
๐ Deployment
Docker Production Deployment
-
Build for production:
# Build optimized images docker-compose -f docker-compose.prod.yml build # Deploy to production docker-compose -f docker-compose.prod.yml up -d
-
Environment Configuration:
# Create production environment cp docker.env .env.prod # Update for production: # - Change passwords and secrets # - Set RUST_ENV=production # - Configure proper database URL # - Set up HTTPS/SSL
Manual Deployment
-
Build the application:
# Backend cd backend && cargo build --release # Frontend cd frontend && trunk build --release
-
Deploy artifacts:
- Backend binary:
target/release/backend - Frontend files:
dist/directory - Database: Run migrations on production DB
- Backend binary:
๐งช Development
Development Scripts
./dev-start.sh- Start all development services./dev-stop.sh- Stop all development servicesdocker-compose up -d- Start Docker servicesdocker-compose down- Stop Docker services
Code Quality
The codebase maintains zero warnings and follows Rust best practices:
# Check compilation (should show 0 warnings) cargo check --workspace # Format code cargo fmt --all # Advanced linting cargo clippy --all-targets --all-features # Security audit cargo audit
Testing
# Backend tests cd backend && cargo test # Frontend WASM tests cd frontend && wasm-pack test --headless --firefox # Integration tests cargo test --workspace
๐ Documentation
Core Documentation
- DEFAULT_SETUP.md - Default data and configuration
- DEVELOPMENT.md - Development environment setup
- DATABASE_SETUP.md - Database configuration and management
- SECURITY.md - Security features and best practices
- RAYDT-STACK.md - Architecture and technology stack
Plugin System
- PLUGIN_DEVELOPMENT.md - Plugin development guide
- PLUGIN_ARCHITECTURE.md - Plugin system architecture
- PLUGIN_MERKLE_VERIFICATION.md - Plugin security
๐ฏ Key Improvements
Recent Major Updates
- โ Live Edit Mode: Complete rewrite with multi-property support
- โ Default Data Setup: Professional configuration out-of-the-box
- โ Docker Integration: One-command deployment with health checks
- โ Code Cleanup: Zero compiler warnings across entire codebase
- โ Template System: 8 professional component templates
- โ Design System: Integrated typography and color management
Performance Optimizations
- WebAssembly: Frontend compiled to WASM for maximum performance
- Zero-Copy: Efficient data serialization and transfer
- Component Caching: Smart rendering with minimal updates
- Database Optimization: Indexed queries and connection pooling
Security Features
- Session-Based Auth: Secure authentication without JWT vulnerabilities
- Input Sanitization: XSS and injection prevention
- File Upload Security: Type validation and size limits
- CORS Configuration: Proper cross-origin request handling
๐ค Contributing
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Make your changes with proper testing
- Ensure zero warnings:
cargo check --workspace - Submit a pull request
Development Guidelines
- Follow Rust best practices and idioms
- Maintain zero compiler warnings
- Add tests for new features
- Update documentation for significant changes
- Use the provided development scripts
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐ Acknowledgments
- Rust Community for the amazing ecosystem
- Yew Framework for WebAssembly frontend capabilities
- Diesel ORM for type-safe database operations
- Axum Framework for high-performance HTTP handling
- PostgreSQL for reliable data persistence
๐ Ready to Get Started?
Take a look at the Screenshots to see what you'll be building with, then jump right in:
# One command to rule them all git clone https://github.com/yourusername/my_rust_cms.git cd my_rust_cms docker-compose up -d # Visit http://localhost:8080 and start building!
Default Login: admin / admin
Your professional Rust CMS is ready to use with beautiful gradients, live editing, and modern design! ๐






