jelliott
Phoenix 1.5 Endpoint not starting in release
I just updated an application to Phoenix 1.5 following the instructions here: phx-1.5-upgrade.md · GitHub
Everything works beautifully in development mode, but when I build my (Docker) release the Endpoint doesn’t seem to start correctly, and won’t accept connections. It seems to be running, because if I try to start it I get this:
iex> MyAppWeb.Endpoint.start_link()
{:error, {:already_started, #PID<0.4364.0>}}
I never get the “Running MyAppWeb.Endpoint with cowboy 2.7.0 at 0.0.0.0:4000 (http)” log message, but I also don’t see any errors on startup. I’ve enabled debug logging in the release and didn’t see anything useful there. The release configuration is pretty much identical to a similar app using Phoenix 1.4 that works fine, including the server: true option, port configuration, etc.
Any ideas on how to debug this?
Marked As Solved
jelliott
Just figured this out after a couple hours of debugging. It was a typo in my releases config. I had configured MyApp.Endpoint instead of MyAppWeb.Endpoint.
Popular in Questions
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #advent-of-code
- #elixirconf-us
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #performance









