Skip to content
Orbix Laravel · Bootstrap 5 v1.0.5

Installation

The steps are the same for orbix-laravel/ (full template) and orbix-laravel-starterkit/ (starter kit).

1. Copy the project

Extract the ZIP and copy orbix-laravel/ to your projects folder (rename it as you like). Open a terminal in that folder.

2. Install the PHP dependencies

composer install

3. Create the environment file

cp .env.example .env            # Windows (cmd): copy .env.example .env
php artisan key:generate

The defaults work out of the box: APP_LOCALE=en, file sessions and file cache, no database.

4. Run it

php artisan serve

Open http://localhost:8000. The prebuilt assets in public/build/bootstrap are used, so the template is ready without Node.js.

5. Install the front-end tooling (to customize CSS and JavaScript)

npm install
npm run build        # production assets in public/build/bootstrap

For day-to-day work, run the Vite dev server with hot reload next to the PHP server:

php artisan serve    # terminal 1
npm run dev          # terminal 2

composer run setup runs steps 2 to 5 in one go.

npm scriptWhat it does
npm run devVite dev server with hot reload
npm run buildProduction build of the Bootstrap 5 assets into public/build/bootstrap
npm run assetsRegenerates the icon sprite, the boot script and the icon sets (part of dev and build)
npm run typecheckTypeScript check of resources/js

6. Run the tests (optional)

npm run build
php artisan test     # or: vendor/bin/phpunit

Production build

composer install --no-dev --optimize-autoloader
npm ci && npm run build
php artisan config:cache
php artisan route:cache
php artisan view:cache

In .env set APP_ENV=production, APP_DEBUG=false and APP_URL to your domain. Point the web server document root to public/ and make storage/ and bootstrap/cache/ writable by the web server user.

Shared hosting

  1. Build locally (composer install --no-dev --optimize-autoloader and npm run build).
  2. Upload the whole project outside the public web folder (for example ~/orbix).
  3. Point the domain (or subdomain) document root to ~/orbix/public. If the host does not allow that, copy the contents of public/ into public_html/ and update the two paths in public_html/index.php (__DIR__.'/../vendor/autoload.php' and __DIR__.'/../bootstrap/app.php') so they point to ~/orbix.
  4. Create .env with an APP_KEY (run php artisan key:generate --show locally and paste the value).
  5. Set the permissions of storage/ and bootstrap/cache/ to 775.

Laravel Forge, Ploi or any VPS

Create a site with public as the web directory and use this deploy script:

composer install --no-dev --optimize-autoloader
npm ci && npm run build
php artisan config:cache && php artisan route:cache && php artisan view:cache

Docker

Any PHP 8.3+ image with the extensions listed in Requirements works. A minimal setup: build the assets with a node:24 image in a first stage (npm ci && npm run build), then copy the project into a php:8.3-fpm (with Nginx) or php:8.3-apache image, run composer install --no-dev --optimize-autoloader, set the document root to /var/www/html/public and give the web server user write access to storage/ and bootstrap/cache/. Laravel Sail also works for local development (composer require laravel/sail --dev).

Troubleshooting

ProblemSolution
Vite manifest not foundRun npm install && npm run build, or check that public/build/bootstrap/manifest.json was uploaded
No application encryption key has been specifiedRun php artisan key:generate
Blank page or error 500Check storage/logs/laravel.log; make storage/ and bootstrap/cache/ writable
Changes made with npm run dev are not visibleDelete public/hot if the dev server was stopped abruptly, then reload
Old styles after an updateRun npm run build, clear the browser cache and run php artisan view:clear