Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v2.0.13: Can not run eval right after building a release #662

Closed
jesseshieh opened this issue May 16, 2019 · 9 comments
Closed

v2.0.13: Can not run eval right after building a release #662

jesseshieh opened this issue May 16, 2019 · 9 comments

Comments

@jesseshieh
Copy link
Contributor

Steps to reproduce

# install distillery 2.0.13
mix release.init
rm -rf _build/
MIX_ENV=prod mix release --env=prod
_build/prod/rel/gigalixir_getting_started/bin/gigalixir_getting_started eval 'IO.inspect 123+123'

Produces the error

Unable to load vm.args and NAME is not exported, unable to configure node!

In 2.0.12, it works fine.

I think this is because the vm.args file below does not exist yet.

_build/prod/rel/gigalixir_getting_started/var/vm.args

After running

_build/prod/rel/gigalixir_getting_started/bin/gigalixir_getting_started describe

the eval command above works fine. I'm guessing this is because the describe command creates the vm.args file.

Here is the repo I used to reproduce, which just uses the default generated rel/config.exs
https://github.com/gigalixir/gigalixir-getting-started/blob/js/cookie/rel/config.exs

@ggcampinho
Copy link

I have the same issue running the help/console commands, that are fixed after running foreground

@bitwalker
Copy link
Owner

I'll take a look ASAP

bitwalker added a commit that referenced this issue May 16, 2019
@bitwalker
Copy link
Owner

bitwalker commented May 16, 2019

@jesseshieh @ggcampinho Can you all verify the fix I pushed to master? I'm pretty sure the problem is that partial_config_release always assumed that the main app had been run at least once, and it just needs to check that assumption before proceeding without generating configs.

EDIT: I created a test app and ran the same steps that @jesseshieh laid out, and all was well, but I just want to make sure it works in scenarios where we know it failed

@geofflane
Copy link

Seeing similar behavior on 2.0.13 with a custom migration command that we run on CI in our remote environment. Downgrading to 2.0.12 worked.

@djantea
Copy link

djantea commented May 17, 2019

Hi,
@bitwalker, im my case the problem was solved wit the version from master.
Thank you.

@jesseshieh
Copy link
Contributor Author

@bitwalker Fix verified! Thanks for such a quick turnaround!

@bitwalker
Copy link
Owner

Thanks @djantea and @jesseshieh! New release published (2.0.14)

@ggcampinho
Copy link

ggcampinho commented May 17, 2019

A little bit late, but confirming that it fixed for me as well :) Thanks 💛

@DavidVII
Copy link

Late here too, but thanks for the quick turnaround on this 🙌

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants