Local Development
Learn how to set up your local environment for offline development with supastarter
The repository includes a complete local development environment with PostgreSQL and SeaweedFS S3-compatible storage. This allows you to run your entire application stack locally, making development faster and more reliable (also offline).
Prerequisites
Running third-party services locally with Docker Compose for offline development
Start the local development services (PostgreSQL and SeaweedFS):
docker compose up -dThis will start:
- PostgreSQL on port
5432(database:supastarter, user:postgres, password:postgres) - SeaweedFS S3-compatible storage on port
9000(API) and9001(Admin UI)- Access the SeaweedFS Admin UI at http://localhost:9001
- Credentials:
seaweedadmin/seaweedadmin - The
avatarsbucket is created on boot
To start only storage (when PostgreSQL is already running):
docker compose up -d seaweedfsEnvironment Configuration
Use the following environment variables to access your local development environment:
# Database
DATABASE_URL="postgresql://postgres:postgres@localhost:5432/supastarter"
# Storage (SeaweedFS)
S3_ACCESS_KEY_ID="seaweedadmin"
S3_SECRET_ACCESS_KEY="seaweedadmin"
S3_ENDPOINT="http://localhost:9000"
S3_REGION="us-east-1"
NUXT_PUBLIC_AVATARS_BUCKET_NAME="avatars"If your existing .env.local still uses minioadmin, update it to the SeaweedFS credentials above.
Stopping Services
docker compose downTo also remove the data volumes:
docker compose down -vGet mails on local development environment
To not have to set up a mail service to get mails on your local development environment, you can use console provider in packages/mail.
This will print the mails to the console. Simply update the packages/mail/provider/index.ts like this:
export * from "./console";