This is a Next.js project bootstrapped with create-next-app
.
- Run yarn install both in this directory and the parent directory
- Run
yarn docker:start
If you experience any issues with posgres, make sure you do not already have a postgres service running locally outside of docker.
- Add .env.local (see .env.example)
- yarn db:migrate:local
First, run the development server:
yarn dev
Open http://localhost:3000 with your browser to see the result.
Open http://localhost:8025 to open the development mailbox.
To learn more about Next.js, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
You can check out the Next.js GitHub repository - your feedback and contributions are welcome!
- Install fly.io https://fly.io/docs/speedrun/
- Add .env.production file with
DATABASE_URL
set (currently required for prisma db push) yarn deploy
- Deploy a postgresql database on fly.io (lightsats-db)
flyctl postgres attach --app lightsats lightsats-db
ORflyctl secrets set DATABASE_URL=postgres://postgres:[email protected]:5432/lightsats?schema=public --app lightsats
- set NEXTAUTH_SECRET:
flyctl secrets set NEXTAUTH_SECRET=XXXXXXXXXXXXXXXXXXXXX --app lightsats-prod
- add other secrets (see .env.example)
- create .sentryclirc (see .sentryclirc.example)
- Staging deployments (https://lightsats.fly.dev/) will happen on push to
main
- Production deployments (https://lightsats.com/) will happen on push to
production
TODO