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

Remove BUNDLE_BIN and add GEM_HOME/bin back to PATH #209

Merged
merged 1 commit into from
May 24, 2018

Conversation

tianon
Copy link
Member

@tianon tianon commented May 21, 2018

See #208 (comment)

This is a follow-up to #208.

Refs #188, #191, #193

@tianon
Copy link
Member Author

tianon commented May 21, 2018

I tested with both Dockerfiles from #208's description, and they both still build successfully (and rake is in PATH after the build, and I'm able to gem install passenger and get passenger-config in PATH, which is how we noticed this breakage in the first place).

tianon added a commit to infosiftr/stackbrew that referenced this pull request May 21, 2018
@tianon
Copy link
Member Author

tianon commented May 21, 2018

I wonder if this means we should at least partially revert docker-library/docs#1221 too? I guess it's still pretty relevant.

@tianon tianon force-pushed the remove-bundle-bin branch 2 times, most recently from 928d3bc to 0c8dfb3 Compare May 21, 2018 22:28
@tianon
Copy link
Member Author

tianon commented May 21, 2018

Yay green finally!

@tianon tianon force-pushed the remove-bundle-bin branch from 0c8dfb3 to af6210c Compare May 22, 2018 21:36
@mvisonneau
Copy link

Thanks for the fix @tianon. Any idea when this is going to be merged and released ? I believe that a lot of people are going to be impacted by the recent release on most tags that breaks the gems binary path.

bandesz added a commit to alphagov/paas-docker-cloudfoundry-tools that referenced this pull request May 24, 2018
In the latest Ruby alpine image they removed the /usr/local/bundle/bin path
from the PATH which causes installed gem binaries not to be on the path
anymore.

We need to temporarily fix this until they sort out
docker-library/ruby#209.
bandesz added a commit to alphagov/paas-docker-cloudfoundry-tools that referenced this pull request May 24, 2018
In the latest Ruby alpine image they removed the /usr/local/bundle/bin path
from the PATH which causes installed gem binaries not to be on the path
anymore.

We need to temporarily fix this until they sort out
docker-library/ruby#209.
@tianon
Copy link
Member Author

tianon commented May 24, 2018

Doh, good point; @yosifkit can you review this ASAP today? 😇

@yosifkit yosifkit merged commit 377b3e6 into docker-library:master May 24, 2018
@yosifkit yosifkit deleted the remove-bundle-bin branch May 24, 2018 16:34
@mvisonneau
Copy link

thanks 🙏 !

tianon added a commit to infosiftr/stackbrew that referenced this pull request May 24, 2018
- `drupal`: new arches (thanks to Alpine 3.4 deprecation)
- `redmine`: update Redmine 3.3 to Ruby 2.3, remove Redmine 3.2 (docker-library/redmine#115)
- `ruby`: remove `BUNDLE_BIN`, adjust `PATH` (docker-library/ruby#209)
- `wordpress`: new arches (thanks to Alpine 3.4 deprecation)
@Mehonoshin
Copy link

It looks like dockerhub still contains broken images.

I get the following with the latest image from there

 /bin/sh: 1: rails: not found
The command '/bin/sh -c rails assets:precompile' returned a non-zero code: 127

@Mehonoshin
Copy link

It looks like it does not work when I use bundle install --deployment --without development test
With regular, full installation it works.
@tianon do you have any ideas, why could that happen?

@tianon
Copy link
Member Author

tianon commented May 29, 2018

Gah, bundle install --deployment drops bits into ./vendor/bundle/... instead of the normal Bundler directory. 😞

From https://bundler.io/v1.0/man/bundle-install.1.html#DEPLOYMENT-MODE:

Gems are installed to vendor/bundle not your default system location

Was BUNDLE_BIN putting even those binstubs in /usr/local/bundler/bin before?

@Mehonoshin
Copy link

yep, it worked before

shibukk added a commit to shibukk/rails_application_template that referenced this pull request Jul 20, 2018
shibukk added a commit to shibukk/rails_simple_template that referenced this pull request Jul 20, 2018
@bkeroackdsc
Copy link

Any chance we can get this applied to the ruby 2.1.x image as well?

@tianon
Copy link
Member Author

tianon commented Sep 14, 2018 via email

@bkeroackdsc
Copy link

Fair enough. Thanks for the response!

flavorjones added a commit to sparklemotion/nokogiri that referenced this pull request Jun 7, 2020
which create binstubs that set BUNDLER_GEMFILE

see rubygems/bundler#6162
see rubygems/bundler#6154
and see docker-library/ruby#209 which was the fix for cruby docker images
flavorjones added a commit to sparklemotion/nokogiri that referenced this pull request Aug 31, 2020
Earlopain added a commit to Earlopain/official-images-docs that referenced this pull request Jul 5, 2024
tianon pushed a commit to docker-library/docs that referenced this pull request Jul 8, 2024
* Update examples from "ruby:3.0" to "ruby:3.3"

Previous: #2051

3.0 images are not build/updated anymore

* Drop mentions of unused bundler env variables for ruby

Dropped in:
* docker-library/ruby#209
* docker-library/ruby#306
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

Successfully merging this pull request may close these issues.

7 participants