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

Bundler binstubs can reference old removed app releases which breaks the deploy #63

Open
roback opened this issue May 11, 2021 · 0 comments
Labels

Comments

@roback
Copy link
Member

roback commented May 11, 2021

Discovered in https://github.com/twingly/systemutil/issues/223

A deploy failed because the forman binstub, which we use when generating the systemd scripts, was referencing the path of an old release.

sudo fetch(:chruby_exec), "#{fetch(:chruby_ruby)} -- #{fetch(:bundle_binstubs)}/foreman export systemd /etc/systemd/system -a #{fetch(:application)} -u \`whoami\` -l #{shared_path}/log"

There's an issue related to this at capistrano/bundler#111

We could fix this by, either just add set :bundle_check_before_install, false, which will bypass this check in capistrano-bundler. This will cause bundler to generate binstubs on each deploy, and also has the side-effect of running bundle install on each deploy, which takes ~1 second instead of the faster bundle check.

Another fix would be to make our own custom task which regenerates the binstubs using bundle binstubs on each deploy.

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

No branches or pull requests

1 participant