Trying to get Next.js + SQLite combo working on Easypanel with Docker
In real app, do not commit .env.development
& .env.production
to source control like Git. Add it to .gitignore
& .dockerignore
or better yet use dotenvx for environment variables.
NPM Scripts appended with :prod
are production scripts and those without anything appended are scripts to be used in development.
pnpm db:generate
generates migration files fordevelopment
at/src/app/db/migrations
pnpm db:migrate
generatesusers.dev.sqlite
fordevelopment
pnpm turbo
orpnpm dev
runs the local server.- if you try to interact with database by clicking add, delete, or get buttons, then it creates
*.sqlite-shm
or*.sqlite-wal
files. read more about wal mode at https://til.simonwillison.net/sqlite/enabling-wal-mode.
make build-production
to build a Docker Container forproduction