[10/12] RUN mix compile
Unchecked dependencies for environment prod:
* heroicons (https://github.com/tailwindlabs/heroicons.git - v2.1.1)
lock outdated: the lock is outdated compared to the options in your mix.exs. To fetch locked version run "mix deps.get"
** (Mix) Can't continue due to errors on dependencies
âś• [10/12] RUN mix compile
process "/bin/bash -ol pipefail -c mix compile" did not complete successfully: exit code: 1
Strangely mix compile works on local. I am looking for guidance on how to deploy this app. I am using SQLite for local development and wanna use Postgres for Prod.
Hello, thank you for your reply. It was very useful in general but I am still stuck specifically for railway, as they have the docker template and I don’t control that.
Or did I not understand the tagged issue correctly, and I need to do something else on my end ?
Could this be because I am on Phoenix v1.7.21 ? I specifically picked phx_new for this version of phoenix and created this app.
I think this problem is somehow specific to Nixpacks.
I was experiencing the same problem on Coolify (which also uses Nixpacks under the hood), with the Dockerfile generated by mix phx.gen.release --docker. Disabling the docker build cache has no effect but also, I haven’t been able to reproduce the error on a local docker.
I’m not very familiar with how Nixpacks works exactly - I tried tweaking my Dockerfile (e.g. adding –force on mix compile) but it seems that was not the mix compile that triggers the failure - Nixpacks is calling mix compile all by itself somehow when it detects and Elixir project.
So finally, I configured Coolify to treat my app as a “generic docker” (by setting the buildpack to Docker instead of Nixpacks). This solved the issue (using the default Dockerfile and no need to force or disable caching).