0

Puppet

[root@ns1 ~]# puppet --version
4.10.1

Repositories (used Foreman 1.12 as the next versions are not supported in Centos 6)

[root@ns1 ~]# yum repolist enabled
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.coreix.net
 * epel: mirror.nl.leaseweb.net
 * extras: repo.uk.bigstepcloud.com
 * remi: remi.mirror.wearetriple.com
 * remi-safe: remi.mirror.wearetriple.com
 * updates: repo.uk.bigstepcloud.com
repo id                                                                                          repo name                                                                                                                             status
base                                                                                             CentOS-6 - Base                                                                                                                        6,706
centos-sclo-rh                                                                                   CentOS-6 - SCLo rh                                                                                                                     5,553
centos-sclo-sclo                                                                                 CentOS-6 - SCLo sclo                                                                                                                     300
epel                                                                                             Extra Packages for Enterprise Linux 6 - x86_64                                                                                        12,309
extras                                                                                           CentOS-6 - Extras                                                                                                                         45
foreman                                                                                          Foreman 1.12                                                                                                                             460
foreman-plugins                                                                                  Foreman plugins 1.12                                                                                                                     240
percona-release-noarch                                                                           Percona-Release YUM repository - noarch                                                                                                   43
percona-release-x86_64                                                                           Percona-Release YUM repository - x86_64                                                                                                1,328
puppetlabs-deps                                                                                  Puppet Labs Dependencies El 6 - x86_64                                                                                                    77
puppetlabs-products                                                                              Puppet Labs Products El 6 - x86_64                                                                                                       565
remi                                                                                             Remi's RPM repository for Enterprise Linux 6 - x86_64                                                                                  4,190
remi-safe                                                                                        Safe Remi's RPM repository for Enterprise Linux 6 - x86_64                                                                             1,782
updates                                                                                          CentOS-6 - Updates                                                                                                                       354
repolist: 33,952

Foreman

[root@ns1 ~]# yum -y install foreman-installer

[root@ns1 ~]# foreman-installer
...
 Execution of '/usr/bin/yum -d 0 -e 0 -y install foreman-proxy' returned 1: Error: Package: foreman-proxy-1.12.4-1.el6.noarch (foreman)
 /Stage[main]/Foreman_proxy::Install/Package[foreman-proxy]/ensure: change from purged to present failed: Execution of '/usr/bin/yum -d 0 -e 0 -y install foreman-proxy' returned 1: Error: Package: foreman-proxy-1.12.4-1.el6.noarch (foreman)                                                                                                                                                                                                                                          
[FAILED]main]/Puppet::Server::Service/Service[puppetserver]: Failed to call refresh: Could not start Service[puppetserver]: Execution of '/sbin/service puppetserver start' returned 1: Starting puppetserver: [FAILED]
[FAILED]main]/Puppet::Server::Service/Service[puppetserver]: Could not start Service[puppetserver]: Execution of '/sbin/service puppetserver start' returned 1: Starting puppetserver: [FAILED]
...

foreman-proxy

[root@ns1 ~]# yum install foreman-proxy
Loaded plugins: fastestmirror
Setting up Install Process
Loading mirror speeds from cached hostfile
 * base: mirrors.coreix.net
 * epel: mirror.nl.leaseweb.net
 * extras: repo.uk.bigstepcloud.com
 * remi: remi.mirror.wearetriple.com
 * remi-safe: remi.mirror.wearetriple.com
 * updates: repo.uk.bigstepcloud.com
Resolving Dependencies
--> Running transaction check
---> Package foreman-proxy.noarch 0:1.12.4-1.el6 will be installed
--> Processing Dependency: rubygem(sinatra) for package: foreman-proxy-1.12.4-1.el6.noarch
--> Finished Dependency Resolution
Error: Package: foreman-proxy-1.12.4-1.el6.noarch (foreman)
           Requires: rubygem(sinatra)
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

--skip-broken key does not help in this case

rubygem-sinatra

[root@ns1 ~]# yum install rubygem-sinatra
Loaded plugins: fastestmirror
Setting up Install Process
Loading mirror speeds from cached hostfile
 * base: mirrors.coreix.net
 * epel: mirror.nl.leaseweb.net
 * extras: repo.uk.bigstepcloud.com
 * remi: remi.mirror.wearetriple.com
 * remi-safe: remi.mirror.wearetriple.com
 * updates: repo.uk.bigstepcloud.com
No package rubygem-sinatra available.
Error: Nothing to do

[root@ns1 ~]# gem install sinatra
ERROR:  Error installing sinatra:
        rack requires Ruby version >= 2.2.2.

Tried previous version:

[root@ns1 ~]# gem install sinatra -v 1.4.8
Successfully installed rack-1.6.8
Successfully installed rack-protection-1.5.3
Successfully installed sinatra-1.4.8
3 gems installed
Installing ri documentation for rack-1.6.8...
Installing ri documentation for rack-protection-1.5.3...
Installing ri documentation for sinatra-1.4.8...
Installing RDoc documentation for rack-1.6.8...
Installing RDoc documentation for rack-protection-1.5.3...
Installing RDoc documentation for sinatra-1.4.8...

However, foreman-proxy still cannot be installed due to the same error:

Error: Package: foreman-proxy-1.12.4-1.el6.noarch (foreman)
           Requires: rubygem(sinatra)

2 Answers 2

0

You can download Sinatra rpm from http://www.rpmseek.com/rpm-pl/rubygem-sinatra.html?hl=com&cs=rubygems:RE:0:0:0:0:800 and install it.

0

When you try to install foreman-proxy with yum it don\t know about your gem packages. It operates only with rpm database. So you should install rubygem-sinatra by yum, rubygem-sinatra could be located in epel repo. You could it install by command yum install epel-release. And after it run yum install rubygem-sinatra

I found it there by command:

[root@~ ]# yum provides rubygem-sinatra
1:rubygem-sinatra-1.4.8-2.el7.noarch : Ruby-based web application framework 
Repo        : epel

My answer tested in CentOS 7.

Update

For CentOS 6 you could try to install RPM from this site sudo rpm -i https://driesrpms.eu/redhat/el6/en/x86_64/dries.all/RPMS/rubygem-sinatra-1.1.3-1.el6.rf.noarch.rpm --nodeps

6
  • [root@ns1 ~]# yum install epel-release Package epel-release-6-8.noarch already installed and latest version Nothing to do [root@ns1 ~]# yum provides rubygem-sinatra Warning: 3.0.x versions of yum would erroneously match against filenames. You can use "*/rubygem-sinatra" and/or "*bin/rubygem-sinatra" to get that behaviour No Matches found It seems that rubygem-sinatra is not included in the EPEL 6.8 repository dl.fedoraproject.org/pub/epel/6/x86_64
    – Oleksandr
    Jun 10, 2017 at 15:43
  • @Alexander you use CentOS 6? Jun 10, 2017 at 15:45
  • Yes, as it is mentioned in the subject line. It seems that this version is outdated for the desired setup.
    – Oleksandr
    Jun 10, 2017 at 15:47
  • @Alexander sorry, my fault. Please check update. Jun 10, 2017 at 15:53
  • It asked for 9 dependencies more. I resolved most of them using the website you provided, except for rubygem-erubis (not available) and rubygem-nokogiri (the website says it depends on rubygem-hoe that is installed by me) rpm -i https://driesrpms.eu/redhat/el6/en/x86_64/dries.all/RPMS/rubygem-sinatra-1.1.3-1.el6.rf.noarch.rpm error: Failed dependencies: rubygem(erubis) is needed by rubygem-sinatra-1.1.3-1.el6.rf.noarch rubygem(nokogiri) is needed by rubygem-sinatra-1.1.3-1.el6.rf.noarch
    – Oleksandr
    Jun 10, 2017 at 16:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .