voxpupuli / librarian-puppet

MIT License
95 stars 38 forks source link

Failing to install activesupport-5.0.0.beta3.gem on Ruby 2.1.8. #6

Closed alex-harvey-z3q closed 3 years ago

alex-harvey-z3q commented 8 years ago

This is on the latest Puppet Labs CentOS 7 vagrant box:

[root@centos-72-x64 ~]# /opt/puppetlabs/puppet/bin/gem install librarian-puppet --no-ri --no-rdoc
Fetching: thor-0.19.1.gem (100%)
Successfully installed thor-0.19.1
Fetching: librarianp-0.6.3.gem (100%)
Successfully installed librarianp-0.6.3
Fetching: rsync-1.0.9.gem (100%)
Successfully installed rsync-1.0.9
Fetching: concurrent-ruby-1.0.1.gem (100%)
Successfully installed concurrent-ruby-1.0.1
Fetching: i18n-0.7.0.gem (100%)
Successfully installed i18n-0.7.0
Fetching: minitest-5.8.4.gem (100%)
Successfully installed minitest-5.8.4
Fetching: thread_safe-0.3.5.gem (100%)
Successfully installed thread_safe-0.3.5
Fetching: tzinfo-1.2.2.gem (100%)
Successfully installed tzinfo-1.2.2
Fetching: activesupport-5.0.0.beta3.gem (100%)
ERROR:  Error installing librarian-puppet:
        activesupport requires Ruby version >= 2.2.2.
[root@centos-72-x64 ~]# /opt/puppetlabs/puppet/bin/ruby -v
ruby 2.1.8p440 (2015-12-16 revision 53160) [x86_64-linux]
alex-harvey-z3q commented 8 years ago

Workaround:

[root@centos-72-x64 ~]# /opt/puppetlabs/puppet/bin/gem install activesupport --no-ri --no-rdoc
Fetching: activesupport-4.2.6.gem (100%)
Successfully installed activesupport-4.2.6
1 gem installed
[root@centos-72-x64 ~]# /opt/puppetlabs/puppet/bin/gem install librarian-puppet --no-ri --no-rdoc
Fetching: builder-3.2.2.gem (100%)
Successfully installed builder-3.2.2
Fetching: activemodel-4.2.6.gem (100%)
Successfully installed activemodel-4.2.6
Fetching: multipart-post-2.0.0.gem (100%)
Successfully installed multipart-post-2.0.0
Fetching: faraday-0.9.2.gem (100%)
Successfully installed faraday-0.9.2
Fetching: multi_json-1.11.2.gem (100%)
Successfully installed multi_json-1.11.2
Fetching: her-0.6.8.gem (100%)
Successfully installed her-0.6.8
Fetching: puppet_forge-1.0.5.gem (100%)
Successfully installed puppet_forge-1.0.5
Fetching: librarian-puppet-2.2.1.gem (100%)
Successfully installed librarian-puppet-2.2.1
8 gems installed
coredevel commented 8 years ago

@alexharv074, the real workaround:

# Build the forked and fixed version of librarian puppet until the 
# published RubyGem is reflective of the actively maintained repo
cd /usr/local/src

# Clone the repo
git clone https://github.com/voxpupuli/librarian-puppet.git

# Build the gem
cd librarian-puppet && gem build librarian-puppet.gemspec

# Install the gem
gem install --no-ri --no-rdoc librarian-puppet-2.2.1.gem

# Clean up
cd .. && rm -rf librarian-puppet

What you're doing is circumventing the issue. The RubyGem's version uses the old puppet forge, you need to build the master branch of this repo.

alex-harvey-z3q commented 8 years ago

All I need right now is to install Librarian-puppet, and thanks for explaining what the underlying issue is.

njam commented 8 years ago

Should be fixed with https://github.com/voxpupuli/librarian-puppet/pull/1

coredevel commented 8 years ago

Yes #1 fixes it but only in this repo, it still requires the gem to be built and installed manually as it's not published to RubyGems.

coredevel commented 8 years ago

When #3 is finished it should work as expected.