Error connecting fly pg app to Prisma in a separate app

Hi… The DATABASE_URL typically contains a password, so you generally want to keep it in the secrets vault, instead of in a .env file. The default format for the URL is…


If you wanted to have a separate set of tables for the new app—and just avoid the expense and inconvenience of provisioning a second Postgres machine—then you would use fly pg attach. That command would create a fresh DATABASE_URL and add it into your new app’s secrets automatically.