Laravel
Deploy Laravel with MySQL or Postgres, APP_KEY, queue workers, Horizon and the scheduler.
Step by step: Deploy Laravel to DigitalOcean · Deploy Laravel to Hetzner · Deploy Laravel to Vultr · Deploy Laravel to OVHcloud · Deploy Laravel to Scaleway · Deploy Laravel to UpCloud
- Release:
php artisan migrate --force. - Variables:
DB_HOST,DB_PORT,DB_DATABASE,DB_USERNAME,DB_PASSWORDandAPP_URLfrom your.env.exampleare wired to the provisioned database and the app’s URL.APP_KEYis generated in Laravel’sbase64:format. - Workers:
php artisan queue:work, orphp artisan horizonwhenlaravel/horizonis installed. - Octane: with
laravel/octaneincomposer.jsonand no Dockerfile, the web process runsphp artisan octane:start --server=frankenphp --host=0.0.0.0 --port=$PORTautomatically. - Reverb: with
laravel/reverbincomposer.json, areverbworker runningphp artisan reverb:startis added for you.
Queue workers and the scheduler, as processes
queue (or horizon), reverb and a scheduler process are the same image as web, started with a different artisan command — one codebase and one build, several process types, each scaled on its own.
web: php artisan octane:start --server=frankenphp --host=0.0.0.0 --port=$PORT
queue: php artisan queue:work
scheduler: php artisan schedule:work
Railyard adds queue (or horizon when it’s installed) automatically; a scheduler process running schedule:work is offered too once routes/console.php or bootstrap/app.php schedules anything. Prefer Railyard’s own Cron instead and have it run php artisan schedule:run on a fixed interval — either works, since schedule:run only fires tasks that are actually due. Add more processes from the Workers tab, or scale what’s there from the CLI:
railyard scale my-app queue=2
Queue and cache backend
QUEUE_CONNECTION, CACHE_STORE, SESSION_DRIVER or BROADCAST_CONNECTION set to redis in your .env.example (or laravel/horizon itself) provisions Redis and injects its connection variables automatically — no addon to add by hand. The database follows the same rule: DB_CONNECTION=pgsql or mysql in .env.example decides which engine gets provisioned.
Config and secrets
Every variable Laravel’s config reads with env() is a plain var under Variables, or set with railyard env:set my-app KEY=VALUE — never baked into the image, so the same build runs unchanged from staging through production: dev/prod parity, not a rebuild per environment. APP_KEY is generated once in Laravel’s own base64: format and encrypted; third-party keys are never invented. Point at a database or Redis running as its own service on the canvas with ${{redis.RAILYARD_PRIVATE_URL}} — resolved per environment. See Variables and secrets.
Deploy it
- From a repo: paste the Git URL, or pick it from the picker once GitHub is connected — Railyard reads
composer.jsonand.env.example, fills inartisan migrate, the queue worker and the provisioned database, and deploys on every push. - From the CLI:
railyard create my-app https://github.com/me/my-app --addons mysql,redis, orrailyard git:remote && git push railyard mainfrom inside the repo. - One click: add the deploy button to your README, or publish to the template catalog so anyone can launch it with its addons and variables already filled in.