How do you get the Phoenix.new application to connect to the hosted managed postres that fly.io hosts.
I can’t login in the command terminal in phoenix.new it just sits and doesn’t pen a browser.
My local db is setup for IP 6.
I have created users dev and prod for both of those instances, I understand I need to set the DB URL as environment var, but it says that the connection times out as it’s getting dropped due to the connection local IPV6 issue.
The command terminal in phoenix.new has flyctl pre-installed, you’ll just need to run flyctl auth login to authenticate against your account. If it can’t open a new browser window in the environment it’ll output an auth link in the terminal output like this:
$ flyctl auth whoami
? You must be logged in to do this. Would you like to sign in? Yes
failed opening browser. Copy the url (https://fly.io/app/auth/cli/<token>) into a browser and continue
Copy and paste that link into your browser to auth the terminal session. You can then run any flyctl commands against your account.
I haven’t used MPG in phoenix.new, but I think you’d probably need to use mpg proxy to get the connection available in the sandbox.