-
Clone/Download repo
-
Install dependencies
npm install
-
Copy
.env.example
to.env
and update the values (if required) -
Start Dockered Postgres and wait for it to start
docker-compose up
# use "docker-compose up -d" to run in background
- Push prisma schema to db
npx prisma db push
- Start the dev server
npm run dev
- use vscode to run eslint on save and disable normal formatting
- use Portainer to manage your docker containers
All commands are run from the root of the project, from a terminal:
Command | Action |
---|---|
npm install |
Installs dependencies |
npm run dev |
Starts local dev server at localhost:3000 |
npm run build |
Build your production site to ./dist/ |
npm start |
Serve your production build locally |
npm run preview |
Preview your build locally, before deploying |
npx prisma db push |
Push prisma schema to db |
npx prisma studio |
Open prisma studio (web db viewer) |
npx prisma migrate dev |
Run prisma migrations (probably not neccessary) |
npx prisma generate |
Generate prisma client |
docker-compose up |
Start Dockered Postgres and wait for it to start |
docker-compose down |
Stop Dockered Postgres |
npm run astro ... |
Run CLI commands like astro add , astro check |
npm run astro --help |
Get help using the Astro CLI |