Running on Neon Postgres
Neon is a fully-managed serverless Postgres service.
Setup
- Create a project on Neon with a given name in a region close to where you will be hosting your Umami project.
- You can also create a Neon project with the Neon CLI:
npx neonctl projects create
. The connection string will be printed to the console.
- You can also create a Neon project with the Neon CLI:
- Get the database connection string with pooled connection enabled. It should look something like this:
postgres://user:passwd@endpoint-pooler.region.aws.neon.build/neondb
.- You can also get the connection string with Neon CLI:
npx neonctl connection-string --project-id <project-id> --pooled
.
- You can also get the connection string with Neon CLI:
- Important: add
?pgbouncer=true&connect_timeout=10
to the connection string you just copied. - Add
DATABASE_URL
to your.env
file:DATABASE_URL=postgres://user:passwd@endpoint-pooler.region.aws.neon.build/neondb?pgbouncer=true&connect_timeout=10
- You should now be able to check the database connection and update the schema (
yarn run build-db && yarn run update-db
). - Follow the Getting started guide starting from the Login step and be sure to change the default password.