Connecting to fly.io database proxy #544
Unanswered
felipesere
asked this question in
Q&A
Replies: 1 comment 3 replies
-
To make matters weird, I can get |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
👋 I have weird issue!
I have my app deployed through Docker on fly.io. There, I can see that it can connect to the DB and has successfully migrated it to the latest schema.
Now I want to write a couple of tasks to do some admin duties. For this, I run the fly proxy
fly proxy 5555:5432 -a $name-db-app
in one tab and then run my task with theDATABASE_URL
overwritten:DATABASE_URL=postgres://$user:$password@localhost:5555/my_db cargo loco task create_user ...
.But I get this error:
I can connect using the exact same DATABASE_URL using
psql
.pgcli
on the other hand fails...I struggle to find the connection (pun intended!)
Beta Was this translation helpful? Give feedback.
All reactions