pglombardo / PasswordPusher

🔐 Securely share sensitive information with automatic expiration & deletion after a set number of views or duration. Track who, what and when with full audit logs.
https://docs.pwpush.com
Apache License 2.0
2.08k stars 359 forks source link

Building master fails on ruby version #187

Closed djerveren closed 3 years ago

djerveren commented 3 years ago

Good morning.

Your project looks really nice, and it's something I want to provide for my users, but I would like to re-brand it a little bit to fit our organisation, so this is what I did:

  1. Forked your PasswordPusher repo
  2. Cloned the fork
  3. Made a minor change in app/assets/stylesheets/global.css
  4. Modified clone URL to point to my repo in containerization/pwpush-postgres/Dockerfile
  5. Committed and pushed to my repo
  6. Built with docker build containerization/pwpush-postgres

This first threw a warning:

Step 8/24 : RUN gem update --system
 ---> Running in 1a3a33df5102
Updating rubygems-update
Successfully installed rubygems-update-3.2.16
Parsing documentation for rubygems-update-3.2.16
Installing ri documentation for rubygems-update-3.2.16
Installing darkfish documentation for rubygems-update-3.2.16
Done installing documentation for rubygems-update after 125 seconds
Parsing documentation for rubygems-update-3.2.16
Done installing documentation for rubygems-update after 0 seconds
Installing RubyGems 3.2.16
/usr/lib/ruby/vendor_ruby/rubygems/defaults/operating_system.rb:50:in `<class:Specification>': undefined method `rubyforge_project=' for class `Gem::Specification' (NameError)
    from /usr/lib/ruby/vendor_ruby/rubygems/defaults/operating_system.rb:49:in `<top (required)>'
    from /var/lib/gems/2.7.0/gems/rubygems-update-3.2.16/lib/rubygems.rb:1348:in `require'
    from /var/lib/gems/2.7.0/gems/rubygems-update-3.2.16/lib/rubygems.rb:1348:in `<top (required)>'
    from setup.rb:23:in `require'
    from setup.rb:23:in `<main>

and later aborted with:

Step 18/24 : RUN bundle install
 ---> Running in a025f15c19af
Your Ruby version is 2.7.0, but your Gemfile specified >= 2.7.2
The command '/bin/sh -c bundle install' returned a non-zero code: 18

Any chance you could take a look at this? I am building this on Fedora 33 with Docker version 20.10.6.

Best regards, Daniel.

pglombardo commented 3 years ago

Hi Daniel - I'm not sure offhand. I can retry the container builds soon but I'm a bit short on time currently.

This seems to have been a Rubygems bug: https://github.com/rubygems/rubygems/issues/3831

The second issue can be resolved by removing (or updating) the Ruby version in the Gemfile.

If you have a chance to dig into these, let me know what you find. If not, I'll get to them soon hopefully.

djerveren commented 3 years ago

Yes, if I remove the ruby ">=2.7.2" requirement from Gemfile and add shared-mime-info to the list of packages apt-get installs, it builds. Thanks!

pglombardo commented 3 years ago

Your Ruby version is 2.7.0, but your Gemfile specified >= 2.7.2

I've fixed this in a branch and it is going out soon. FYI.

pglombardo commented 3 years ago

This has been fixed on master for a while now now but I neglected to update here. I'll try to keep this version lock as wide as possible going forward.

BTW longer term, I hope to add some features to make custom branding a bit simpler. Thanks for reporting!