All Templates / Starters

Laravel

Laravel

An example Laravel application

Deploy Laravel

laravel

railwayapp-templates/laravel

Just deployed

Postgres

railwayapp-templates/postgres-ssl:latest

Just deployed

/var/lib/postgresql/data

Overview

Laravel is the PHP Frameworkfor Web Artisans. Laravel is a web application framework with expressive, elegant syntax. We’ve already laid the foundation — freeing you to create without sweating the small things.

Highlights

  • Dockerfile: The Dockerfile and associated files in docker/ are based on Laravel Sail PHP 8.0
  • Plugin Config: To connect to a Railway Plugin, Postgres for example, you will need to utilize the environment variables listed for that plugin in the Railway Docs. See the .env.example for an example of using these with Postgres.
  • Web server port: Railway dynamically assigns a port for your webserver. We grab the $PORT environment variable in docker/start-container to set this on Artisan serve
  • Logging: Because the disk on Railway containers is ephemeral, we pipe the logs normally output to storage/logs/laravel.log to stdout as seen here
  • APP_KEY: This starter will automatically generate the APP_KEY (php artisan key:generate in the docker/start-container)
  • Migrations: This starter automatically runs migrations on deploy (in the docker/start-container)

Learn More


Deploy Now

Details

Created on Sep 1, 2022

3750 total projects

1555 active projects

80% success on recent deploys

PHP, Blade, JavaScript

Starters



More templates in this category

View Template

New

Django Monolith

Django Monolith

A Django app connected to a Postgres database with Celery and Celery Beat.


Prosper Otemuyiwa

View Template
TanStack + React Starter

TanStack + React Starter

A barebones TypeScript React starter with TanStack Router & Query setup


Kyle Gill

View Template
Scala Play

Scala Play

A simple Play framework app connected to a Postgres database.


Prosper Otemuyiwa