Getting started
So, here we go. Everything was thought to make it easy. Let's get started.
Installation
Steps:
- Clone the repository
- Install dependencies
- Edit environment variables
- Run the server
Clone the repository
git clone https://github.com/wailroth/turbosaas.git # clone the repository
cd turbosaas
npm i #install required dependencies
There you go, you have a working boilerplate. Now, let's edit the environment variables.
Edit environment variables
You can edit the .env
file to configure the environment variables. The .env
file is ignored by git, so you can safely commit it.
You have to rename the .env.example
file to .env
and fill in the required environment variables.
cp .env.example .env
Run the server
Now, let's run the server.
If you want to run the server with a dedicated database container, you can use the following command:
docker-compose up -d
Then, you'll need to create migrations. You can do this by running the following command:
npm run db:fresh
Then, you can run the server with the following command:
npm run dev
And you are done. You can now access the website at http://localhost:3333 (opens in a new tab).
Project structure
The boilerplate is organized in the following way.
π /app
- The backend source code.
π /app/feature/models
- The models of your feature.
π /app/feature/controllers
- The controllers of your application.
π /inertia/app
- The frontend logic
π /inertia/pages
- Pages of your application
π /inertia/components
- All the components.
π /inertia/components/ui
- All the Shadcn components.