Skip to main content
The fastest way to get NutriFit up and running is using the automated setup script.
This method is recommended for most users as it handles all installation steps automatically.

Prerequisites

Before starting, ensure you have:
  • ✅ PHP 8.2+ installed
  • ✅ Composer 2.x installed
  • ✅ Node.js 18.x+ installed
  • ✅ Git installed
See System Requirements for details.

Installation Steps

1

Clone the Repository

First, clone the NutriFit repository to your local machine:
git clone https://github.com/Rubenpro19/NutriFit.git
cd NutriFit
Make sure you’re in the project directory before running the next command.
2

Run Automated Setup

Execute the one-command setup script:
composer run setup
This command automatically performs the following operations:
  1. Installs PHP dependencies via Composer
  2. Creates .env file from .env.example
  3. Generates application key (APP_KEY)
  4. Runs database migrations to create tables
  5. Installs Node.js dependencies via npm
  6. Compiles frontend assets for production
The setup process may take 2-5 minutes depending on your internet connection and system performance.
3

Seed the Database (Required)

Create the default admin user and initial data:
php artisan db:seed
This creates:
  • Admin user with default credentials
  • Sample roles and permissions
  • Initial configuration data
The seeder is required to create the administrator account needed to access the system.
4

Configure Environment (Optional)

The .env file has been created with default values suitable for local development. For basic usage, no changes are needed.However, you may want to customize:
APP_NAME="NutriFit"
APP_LOCALE=es
APP_URL=http://localhost:8000

# Email testing (optional for development)
MAIL_MAILER=log  # Logs emails to storage/logs/laravel.log
See Configuration for detailed environment setup.
5

Start the Development Server

Launch all required services with one command:
composer run dev
This starts three services in parallel:

Web Server

Laravel server running on http://localhost:8000

Queue Worker

Processes email notifications and background jobs

Vite Dev Server

Hot module replacement for instant CSS/JS updates
The terminal will show color-coded output from all three services. Press Ctrl+C to stop all services.
6

Access the Application

Open your browser and navigate to:
http://localhost:8000
You should see the NutriFit welcome page.

Default Admin Credentials

Email: [email protected]
Password: NutriAdmin123
Change the admin password immediately after first login, especially in production environments.

What Gets Installed

The automated setup configures:

Backend Dependencies (composer.json)

{
  "php": "^8.2",
  "laravel/framework": "^12.0",
  "livewire/flux": "^2.1.1",
  "livewire/volt": "^1.7.0",
  "laravel/fortify": "^1.30",
  "barryvdh/laravel-dompdf": "^3.1",
  "laravel/socialite": "^5.23"
}

Frontend Dependencies (package.json)

{
  "tailwindcss": "^4.0.7",
  "vite": "^7.0.4",
  "axios": "^1.7.4",
  "autoprefixer": "^10.4.20"
}

Verification

Verify your installation is complete:
1

Check Database

php artisan migrate:status
All migrations should show “Ran”.
2

Check Assets

ls -la public/build
You should see compiled CSS and JS files.
3

Check Configuration

php artisan config:show app
Verify your app name and environment settings.

Troubleshooting

Port Already in Use

If port 8000 is already in use:
php artisan serve --port=8001

Permission Errors

Ensure storage and cache directories are writable:
chmod -R 775 storage bootstrap/cache

Database Not Found

For SQLite, ensure the file exists:
touch database/database.sqlite
php artisan migrate --force

Node Modules Issues

If asset compilation fails:
rm -rf node_modules package-lock.json
npm install
npm run build

Next Steps

Configuration

Customize environment settings, database, and mail configuration

Getting Started

Learn about NutriFit features and core concepts

Build docs developers (and LLMs) love