Prerequisites
Before installing the Restaurant Management System, ensure your development environment meets these requirements:Required Software
- PHP 8.1 or higher
- Composer 2.x
- Node.js 16.x or higher
- npm 8.x or higher
- MySQL 5.7+ or MariaDB 10.3+
- Git (for cloning the repository)
Verify PHP Extensions
Ensure the following PHP extensions are enabled:- PDO
- mbstring
- OpenSSL
- Tokenizer
- XML
- Ctype
- JSON
- BCMath
- Fileinfo
Installation Steps
Install PHP Dependencies
Install all Composer dependencies defined in This will install:
composer.json:- Laravel Framework (^10.10)
- Laravel Jetstream (^4.3)
- Livewire (^3.0)
- Spatie Laravel Permission (^6.21)
- Laravel Sanctum (^3.3)
- And other dependencies
Install Node Dependencies
Install frontend dependencies and build assets:This installs:
- Tailwind CSS (^3.1.0)
- Vite (^5.0.0)
- Alpine.js (via Livewire)
- SweetAlert2 (^11.14.5)
- Axios (^1.6.4)
Environment Configuration
Copy the example environment file and generate an application key:
The
key:generate command sets the APP_KEY value in your .env file, which is used for encryption.Run Migrations
Create all database tables by running migrations:This creates tables for:
- Users and authentication (users, password_reset_tokens, sessions)
- Roles and permissions (roles, permissions, model_has_roles, etc.)
- Food management (food, categories)
- Orders (orders, order_items, carts)
- Restaurant operations (tables, reservations, chefs)
Seed the Database
Populate the database with initial data including roles and demo users:This creates:
- 4 User Roles: admin, user, chef, mesero
- 4 Demo Users with credentials:
- Admin:
[email protected]/admin1234 - User:
[email protected]/user1234 - Chef:
[email protected]/chef1234 - Waiter:
[email protected]/mesero1234
- Admin:
- Food Categories: Appetizers, Main Courses, Desserts, Beverages, etc.
Storage Link
Create a symbolic link for file storage (for food images):This links
public/storage to storage/app/public for public file access.Verification
After installation, verify everything is working:Check Application Status
Test Database Connection
Verify Permissions
Check that roles and permissions were created:Configuration Options
Application Settings
.env
Session Configuration
.env
The system uses database sessions by default. Make sure the
sessions table exists after running migrations.Mail Configuration (Optional)
For email notifications and password resets:.env
Alternative Installation Methods
Using Laravel Sail (Docker)
For a containerized development environment:Using Laravel Valet (macOS)
For macOS users with Valet installed:http://restaurant-management.test
Troubleshooting
Common Issues
Composer Install Fails
Composer Install Fails
Issue: Memory limit or dependency conflictsSolutions:
Migration Errors
Migration Errors
Issue: Database connection or table already existsSolutions:
Permission Denied Errors
Permission Denied Errors
Issue: Storage or cache directory permissionsSolution:
Assets Not Loading
Assets Not Loading
Issue: Vite not running or build failedSolutions:
Next Steps
Now that your installation is complete:Quick Start Guide
Follow our quickstart guide to create your first menu items and process orders
Authentication
Learn about the role-based authentication system