Installation
Prerequisites
Section titled “Prerequisites”Before you begin, ensure you have the following installed:
- Docker Desktop - For running Laravel Sail containers
- PHP 8.4+ - Required by
composer.jsonfor running Composer locally (optional with Sail; the Sail containers ship PHP 8.5) - Node.js 20+ - Required by Astro 6 (Node 22 recommended)
- pnpm - Package manager for frontend (the repo pins
pnpm@11.0.8viapackageManagerinfrontend/package.json) - Composer - PHP dependency manager
- Intelephense - PHP language server for IDE support (
npm i -g intelephense)
Clone the Repository
Section titled “Clone the Repository”git clone https://github.com/gocimit/volare.gitcd volareBackend Setup
Section titled “Backend Setup”1. Navigate to Backend Directory
Section titled “1. Navigate to Backend Directory”cd backend2. Install PHP Dependencies
Section titled “2. Install PHP Dependencies”composer install3. Configure Environment
Section titled “3. Configure Environment”cp .env.example .envEdit .env with your configuration:
APP_NAME=VolareAPP_ENV=localAPP_DEBUG=trueAPP_URL=http://localhostAPI_URL=http://localhost
DB_CONNECTION=pgsqlDB_HOST=pgsqlDB_PORT=5432DB_DATABASE=volareDB_USERNAME=sailDB_PASSWORD=password
REDIS_HOST=redisQUEUE_CONNECTION=database
# Stripe (see backend/services/stripe-setup for full guide)STRIPE_KEY=pk_test_xxxSTRIPE_SECRET=sk_test_xxxSTRIPE_WEBHOOK_SECRET=whsec_xxxCASHIER_CURRENCY=eurCASHIER_CURRENCY_LOCALE=es_ESAPP_URL is the backend/admin origin. API_URL is the canonical public API
origin used by browser-facing API requests and third-party callbacks. They are
separate on production and should both be set explicitly.
For full Stripe setup including webhook forwarding and test data, see the Stripe Local Setup guide.
4. Start Docker Containers
Section titled “4. Start Docker Containers”./vendor/bin/sail up -dThis starts:
- Laravel application (port 80)
- Queue worker (
queueservice: aerticket and general queues) - Flight-search queue worker (
queue-flightsservice) - PostgreSQL database (port 5432)
- Redis cache (port 6379)
- Nightwatch agent (Laravel Nightwatch monitoring agent)
- Mailpit email testing (port 8025)
5. Generate Application Key
Section titled “5. Generate Application Key”./vendor/bin/sail artisan key:generate6. Run Migrations
Section titled “6. Run Migrations”./vendor/bin/sail artisan migrate7. Seed Database (Optional)
Section titled “7. Seed Database (Optional)”./vendor/bin/sail artisan db:seedFrontend Setup
Section titled “Frontend Setup”1. Navigate to Frontend Directory
Section titled “1. Navigate to Frontend Directory”cd ../frontend2. Install Dependencies
Section titled “2. Install Dependencies”pnpm install3. Start Development Server
Section titled “3. Start Development Server”pnpm devThe frontend will be available at http://localhost:4321.
Cloudflare Deploys (Optional)
Section titled “Cloudflare Deploys (Optional)”The frontend deploys to Cloudflare Workers. Locally you only need the Node adapter, but for Cloudflare builds:
wrangleris already a dev dependency infrontend/package.json- Setting
DEPLOY_TARGET=cloudflareswitchesastro.config.mjsto the@astrojs/cloudflareadapter pnpm deploy-stagingbuilds in staging mode and deploys via Wrangler
Verify Installation
Section titled “Verify Installation”| Service | URL | Port |
|---|---|---|
| Backend API | http://localhost | 80 |
| Admin Panel | http://localhost/admin | 80 |
| API Docs (Swagger) | http://localhost/api/documentation | 80 |
| Telescope | http://localhost/telescope | 80 |
| Frontend | http://localhost:4321 | 4321 |
| Documentation | http://localhost:4322 | 4322 |
| Mailpit | http://localhost:8025 | 8025 |
Common Commands
Section titled “Common Commands”Backend (Laravel Sail)
Section titled “Backend (Laravel Sail)”# Start containers./vendor/bin/sail up -d
# Stop containers./vendor/bin/sail down
# Run tests./vendor/bin/sail artisan test
# Run migrations./vendor/bin/sail artisan migrate
# Clear cache./vendor/bin/sail artisan cache:clear
# Format code./vendor/bin/sail pintFrontend (Astro)
Section titled “Frontend (Astro)”# Development serverpnpm dev
# Production buildpnpm build
# Preview buildpnpm previewTroubleshooting
Section titled “Troubleshooting”Port Conflicts
Section titled “Port Conflicts”If port 80 is in use, modify compose.yaml:
services: laravel.test: ports: - '${APP_PORT:-8080}:80'Database Connection Issues
Section titled “Database Connection Issues”Ensure PostgreSQL container is running:
./vendor/bin/sail psCheck database credentials in .env match compose.yaml.
Permission Denied
Section titled “Permission Denied”If encountering permission issues:
sudo chown -R $USER:$USER .