Skip to content

Installation

Our JetShip uses the TALL Stack (Tailwind CSS, Alpine.js, Livewire, Laravel). Follow these steps to install the JetShip on your system:

Video Tutorial 🎥

Watch this video tutorial for a step-by-step guide on installing JetShip:

Tech Stack

  • PHP 8.2+.
  • Laravel 11.
  • Tailwind CSS.
  • Any database you like (MySQL, Postgres, etc)
  • Redis. (optional for faster caching)

Local development environment

To run our JetShip, you need a local development environment. You can opt for any of the following options:

Herd is a blazing-fast, native Laravel and PHP development environment for Windows and macOS. It includes everything you need to get started with Laravel development, including PHP and nginx. Once you install Herd, you're ready to start developing with Laravel.

Laravel sail

Laravel Sail is a lightweight command-line interface for interacting with Laravel's default Docker development environment. Sail provides a great starting point for building a Laravel application using PHP, MySQL, and Redis without requiring prior Docker experience.

Manual

To manually run our JetShip, you need to manually install PHP, Composer, and a database (such as MySQL, Postgres, SQLite, etc.) on your system. Follow the installation steps below to run the project.

Guide

  • Open the terminal in your root directory & to install the composer packages, run the following command:

    sh
    composer install
  • Run the following command only if you are using the Docker environment (Sail only):

    sh
    ./vendor/bin/sail up -d
  • However, instead of repeatedly typing vendor/bin/sail to execute Sail commands, you may wish to configure a shell alias that allows you to execute Sail's commands more easily (Sail only):

    sh
    alias sail='sh $([ -f sail ] && echo sail || echo vendor/bin/sail)'

    To make sure this is always available, you may add this to your shell configuration file in your home directory, such as ~/.zshrc or ~/.bashrc, and then restart your shell.

  • In the root directory, you will find a file named .env.example rename the given file name to .env and run the following command to generate the key (You can also edit your database credentials here)

    bash
    php artisan key:generate
    bash
    sail artisan key:generate
  • By running the following command, you will be able to get all the dependencies in your node_modules folder:

    bash
    pnpm install
    
    // npm 
    npm install
    
    // yarn 
    yarn
    bash
    sail pnpm install
    
    // npm
    sail npm install
    
    // yarn
    sail yarn
  • You need to set up your database in the .env file. You can choose any database supported by Laravel. For testing purposes, you may use SQLite.

    bash
    DB_CONNECTION=sqlite
    # DB_URL=
    # DB_HOST=
    # DB_PORT=
    # DB_DATABASE=
    # DB_USERNAME=
    # DB_PASSWORD=
  • By running the command below, you will create all the migration tables in the database:

    bash
    php artisan migrate
    bash
    sail artisan migrate
  • Run the following command to populate your database with initial data using seeders:

    bash
    php artisan db:seed
    bash
    sail artisan db:seed
  • Run the following command to create a symbolic link from the storage folder to the public folder, allowing you to access stored files:

    bash
    php artisan storage:link
    bash
    sail artisan storage:link
  • You can run the development server via the dev command, which is useful while developing locally. The development server will automatically detect changes to your files and instantly reflect them in any open browser windows.

    bash
    pnpm run dev
    
    // npm
    npm run dev
    
    // yarn
    yarn dev
    bash
    sail pnpm run dev
    
    // npm
    sail npm run dev
    
    // yarn
    sail yarn dev
  • To serve the application you need to run the following command in the project directory.

    Herd: If you are using Herd, you can access the project in your browser by using the folder name followed by the .test domain.

    sh
    # Project Path: ~/herd/jetship
    
    # type below url in your browser
    
    http://jetship.test

    Sail: If you are using Laravel Sail, you can access the project at http://localhost/

    Manual: To serve the template, run below command:

    sh
    php artisan serve
  • Building for Production: Running the build command will version and bundle your application's assets and get them ready for you to deploy to production:

    bash
    pnpm run build
    
    // npm
    npm run build
    
    // yarn
    yarn build
    bash
    sail pnpm run build
    
    // npm
    sail npm run build
    
    // yarn
    sail yarn build

Creating an Admin User

You can create an admin user by running the below command:

bash
php artisan app:create-admin-user
bash
sail artisan app:create-admin-user

With that use you can access the admin panel by going to /admin and logging in with the credentials you just created.