Closed
Description
Provide environment information
WSL2
Linux 6.6 Ubuntu 24.04.2 LTS
Describe the bug
When following the v4 self-hosted setup guide: https://trigger.dev/docs/self-hosting/docker
1. env.example (fix noted below)
Small fix to .env.example
is needed. On the corepack-offline-rc.0
tag for webapp
:
webapp-1 |
webapp-1 | > @trigger.dev/database@0.0.2 db:migrate:deploy /triggerdotdev/internal-packages/database
webapp-1 | > prisma migrate deploy
webapp-1 |
webapp-1 | Prisma schema loaded from prisma/schema.prisma
webapp-1 | Datasource "db": PostgreSQL database "main", schema "public" at "postgres:5432"
webapp-1 | Error: P1000: Authentication failed against database server at `postgres`, the provided database credentials for `postgres` are not valid.
webapp-1 |
webapp-1 |
webapp-1 | Please make sure to provide valid database credentials for the database server at `postgres`.
webapp-1 | /triggerdotdev/internal-packages/database:
webapp-1 | ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL @trigger.dev/database@0.0.2 db:migrate:deploy: `prisma migrate deploy`
webapp-1 | Exit status 1
There is some misalignment of .env.example
and the postgres config in docker-compose.yml
... these settings worked eventually just for tutorial sake:
# Postgres
# ... prod warning ...
POSTGRES_USER=postgres
POSTGRES_PASSWORD=postgres
POSTGRES_DB=postgres
DATABASE_URL=postgresql://postgres:postgres@postgres:5432/main?schema=public&sslmode=disable
DIRECT_URL=postgresql://postgres:postgres@postgres:5432/main?schema=public&sslmode=disable
2. Task Creation CLI for task creation fails (from the "Get started in 3 minutes" home screen)
dev@machine:~/trigger.dev/hosting/docker$ npx trigger.dev@latest init -p proj_secret -a http://localhost:8030
Trigger.dev (3.3.17)
------------------------------------------------------
┌ Initializing project
│
◇ Retrieved your account details for <email>
│
◇ Configuring project "Project" (proj_secret)
│
◇ Failed to install @trigger.dev/sdk@latest. Rerun command with --log-level debug for more details
X Error: Command failed with exit code 1: corepack pnpm add @trigger.dev/sdk@latest
ERR_PNPM_ADDING_TO_ROOT Running this command will add the dependency to the workspace root, which might not be what you want - if you really meant it, make it explicit by running this command again with the -w flag (or --workspace-root). If you don't want to see this warning anymore, you may set the ignore-workspace-root-check setting to true.
This is mainly a n00b user
issue, but that command has to be run in a fresh folder vs the /hosting/docker
pwd where users will be if they're following the tutorial steps. I was thinking it was some special final init step for the self-hosted env...
Reproduction repo
N/A
To reproduce
Follow v4 Docker tutorial
Additional information
No response
Metadata
Metadata
Assignees
Labels
No labels