Project

General

Profile

Actions

Bug #8809

closed

ruby-foreman-salt installation not working on debian 7

Added by schlag _ over 9 years ago. Updated over 9 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Debian/Ubuntu
Target version:
-
Difficulty:
trivial
Triaged:
Fixed in Releases:
Found in Releases:

Description

cat /etc/debian_version
7.7

cat /etc/apt/sources.list.d/foreman.list
deb http://deb.theforeman.org/ plugins 1.7
deb http://deb.theforeman.org/ wheezy 1.7

apt-get update > /dev/null && apt-get install foreman-installer
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
libaugeas-ruby1.8 libruby1.8 puppet puppet-common ruby ruby-ansi ruby-clamp ruby-hashie ruby-highline ruby-kafo ruby-kafo-parsers ruby-little-plugger ruby-logging ruby-multi-json ruby-powerbar ruby-rdoc ruby-shadow ruby1.8
Suggested packages:
puppet-el vim-puppet etckeeper ruby-selinux librrd-ruby1.8 ri ruby1.8-examples ri1.8 ruby-switch
Recommended packages:
rdoc
The following NEW packages will be installed:
foreman-installer libaugeas-ruby1.8 libruby1.8 puppet puppet-common ruby ruby-ansi ruby-clamp ruby-hashie ruby-highline ruby-kafo ruby-kafo-parsers ruby-little-plugger ruby-logging ruby-multi-json ruby-powerbar ruby-rdoc ruby-shadow ruby1.8
0 upgraded, 19 newly installed, 0 to remove and 28 not upgraded.
1 not fully installed or removed.
Need to get 4,964 kB of archives.
After this operation, 17.2 MB of additional disk space will be used.
Do you want to continue [Y/n]?
Get:1 http://deb.theforeman.org/ wheezy/1.7 ruby-clamp all 0.6.2-2 [9,978 B]
Get:2 http://deb.theforeman.org/ wheezy/1.7 ruby-highline all 1.6.21-1 [38.4 kB]
Get:3 http://ftp.us.debian.org/debian/ wheezy/main libruby1.8 amd64 1.8.7.358-7.1+deb7u1 [2,091 kB]
Get:4 http://deb.theforeman.org/ wheezy/1.7 ruby-rdoc all 3.12.2-1 [230 kB]
Get:5 http://deb.theforeman.org/ wheezy/1.7 ruby-kafo-parsers all 0.0.3-1 [5,594 B]
Get:6 http://deb.theforeman.org/ wheezy/1.7 ruby-little-plugger all 1.1.3-1 [6,954 B]
Get:7 http://deb.theforeman.org/ wheezy/1.7 ruby-logging all 1.8.1-1 [58.0 kB]
Get:8 http://deb.theforeman.org/ wheezy/1.7 ruby-ansi all 1.4.3-1 [25.3 kB]
Get:9 http://deb.theforeman.org/ wheezy/1.7 ruby-hashie all 2.0.5-1 [13.2 kB]
Get:10 http://deb.theforeman.org/ wheezy/1.7 ruby-powerbar all 1.0.11-1 [8,814 B]
Get:11 http://deb.theforeman.org/ wheezy/1.7 ruby-kafo all 0.6.5-1 [39.1 kB]
Get:12 http://deb.theforeman.org/ wheezy/1.7 foreman-installer all 1.7.1-1 [731 kB]
Get:13 http://ftp.us.debian.org/debian/ wheezy/main ruby1.8 amd64 1.8.7.358-7.1+deb7u1 [320 kB]
Get:14 http://ftp.us.debian.org/debian/ wheezy/main libaugeas-ruby1.8 amd64 0.4.1-1.1 [10.6 kB]
Get:15 http://ftp.us.debian.org/debian/ wheezy/main ruby-shadow amd64 2.1.4-2 [13.3 kB]
Get:16 http://ftp.us.debian.org/debian/ wheezy/main puppet-common all 2.7.23-1~deb7u3 [1,065 kB]
Get:17 http://ftp.us.debian.org/debian/ wheezy/main puppet all 2.7.23-1~deb7u3 [278 kB]
Get:18 http://ftp.us.debian.org/debian/ wheezy/main ruby all 1:1.9.3 [6,484 B]
Get:19 http://ftp.us.debian.org/debian/ wheezy/main ruby-multi-json all 1.3.6-1 [13.6 kB]
Fetched 4,964 kB in 0s (5,719 kB/s)
Selecting previously unselected package libruby1.8.
(Reading database ... 66986 files and directories currently installed.)
Unpacking libruby1.8 (from .../libruby1.8_1.8.7.358-7.1+deb7u1_amd64.deb) ...
Selecting previously unselected package ruby1.8.
Unpacking ruby1.8 (from .../ruby1.8_1.8.7.358-7.1+deb7u1_amd64.deb) ...
Selecting previously unselected package libaugeas-ruby1.8.
Unpacking libaugeas-ruby1.8 (from .../libaugeas-ruby1.8_0.4.1-1.1_amd64.deb) ...
Selecting previously unselected package ruby-shadow.
Unpacking ruby-shadow (from .../ruby-shadow_2.1.4-2_amd64.deb) ...
Selecting previously unselected package puppet-common.
Unpacking puppet-common (from .../puppet-common_2.7.23-1~deb7u3_all.deb) ...
Selecting previously unselected package puppet.
Unpacking puppet (from .../puppet_2.7.23-1~deb7u3_all.deb) ...
Selecting previously unselected package ruby.
Unpacking ruby (from .../ruby_1%3a1.9.3_all.deb) ...
Selecting previously unselected package ruby-clamp.
Unpacking ruby-clamp (from .../ruby-clamp_0.6.2-2_all.deb) ...
Selecting previously unselected package ruby-highline.
Unpacking ruby-highline (from .../ruby-highline_1.6.21-1_all.deb) ...
Selecting previously unselected package ruby-rdoc.
Unpacking ruby-rdoc (from .../ruby-rdoc_3.12.2-1_all.deb) ...
Selecting previously unselected package ruby-kafo-parsers.
Unpacking ruby-kafo-parsers (from .../ruby-kafo-parsers_0.0.3-1_all.deb) ...
Selecting previously unselected package ruby-little-plugger.
Unpacking ruby-little-plugger (from .../ruby-little-plugger_1.1.3-1_all.deb) ...
Selecting previously unselected package ruby-multi-json.
Unpacking ruby-multi-json (from .../ruby-multi-json_1.3.6-1_all.deb) ...
Selecting previously unselected package ruby-logging.
Unpacking ruby-logging (from .../ruby-logging_1.8.1-1_all.deb) ...
Selecting previously unselected package ruby-ansi.
Unpacking ruby-ansi (from .../ruby-ansi_1.4.3-1_all.deb) ...
Selecting previously unselected package ruby-hashie.
Unpacking ruby-hashie (from .../ruby-hashie_2.0.5-1_all.deb) ...
Selecting previously unselected package ruby-powerbar.
Unpacking ruby-powerbar (from .../ruby-powerbar_1.0.11-1_all.deb) ...
Selecting previously unselected package ruby-kafo.
Unpacking ruby-kafo (from .../ruby-kafo_0.6.5-1_all.deb) ...
Selecting previously unselected package foreman-installer.
Unpacking foreman-installer (from .../foreman-installer_1.7.1-1_all.deb) ...
Processing triggers for man-db ...
Setting up ruby-foreman-salt (1.1.0) ...
dpkg: error processing ruby-foreman-salt (--configure):
subprocess installed post-installation script returned error exit status 6
Setting up libruby1.8 (1.8.7.358-7.1+deb7u1) ...
Setting up ruby1.8 (1.8.7.358-7.1+deb7u1) ...
update-alternatives: warning: forcing reinstallation of alternative /usr/bin/ruby1.9.1 because link group ruby is broken
update-alternatives: warning: not replacing /usr/bin/rdoc with a link
update-alternatives: warning: not replacing /usr/bin/ri with a link
Setting up libaugeas-ruby1.8 (0.4.1-1.1) ...
Setting up ruby-shadow (2.1.4-2) ...
Setting up puppet-common (2.7.23-1~deb7u3) ...
Setting up puppet (2.7.23-1~deb7u3) ...
Setting up ruby (1:1.9.3) ...
Setting up ruby-clamp (0.6.2-2) ...
Setting up ruby-highline (1.6.21-1) ...
Setting up ruby-rdoc (3.12.2-1) ...
Setting up ruby-kafo-parsers (0.0.3-1) ...
Setting up ruby-little-plugger (1.1.3-1) ...
Setting up ruby-multi-json (1.3.6-1) ...
Setting up ruby-logging (1.8.1-1) ...
Setting up ruby-ansi (1.4.3-1) ...
Setting up ruby-hashie (2.0.5-1) ...
Setting up ruby-powerbar (1.0.11-1) ...
Setting up ruby-kafo (0.6.5-1) ...
Setting up foreman-installer (1.7.1-1) ...
Errors were encountered while processing:
ruby-foreman-salt
E: Sub-process /usr/bin/dpkg returned an error code (1)

sh -xv /var/lib/dpkg/info/ruby-foreman-salt.postinst
#!/bin/sh
  1. postinst script for foreman-* #
  2. see: dh_installdeb(1)

if [ ! -z "${DEBUG}" ]; then
set -x
else
set -e
fi
+ [ ! -z ]
+ set -e

. /usr/share/debconf/confmodule
+ . /usr/share/debconf/confmodule
#!/bin/sh
  1. This is a shell library to interface to the Debian configuration management
  2. system.
###############################################################################
  1. Initialization.
  1. Check to see if a FrontEnd is running.
    if [ ! "$DEBIAN_HAS_FRONTEND" ]; then
    PERL_DL_NONLAZY=1
    export PERL_DL_NONLAZY # Since there is no FrontEnd, this program execs a FrontEnd. # It will then run a new copy of $0 that can talk to it.
    if [ "$DEBCONF_USE_CDEBCONF" ]; then
    exec /usr/lib/cdebconf/debconf $0 "$"
    else
    exec /usr/share/debconf/frontend $0 "$
    "
    fi
    fi
    + [ ! ]
    + PERL_DL_NONLAZY=1
    + export PERL_DL_NONLAZY
    + [ ]
    + exec /usr/share/debconf/frontend /var/lib/dpkg/info/ruby-foreman-salt.postinst
    Use of uninitialized value $action in string eq at /usr/share/debconf/frontend line 27.
    [root@server01:/var/lib/dpkg]# echo $?
    6
Actions #1

Updated by Anonymous over 9 years ago

  • Project changed from Foreman to Salt
  • Status changed from New to Assigned
  • Assignee set to Anonymous

Hi, could you do

export DEBUG=1
dpkg --pending --configure

and paste the relevant output? The foreman package is already installed on that system?

Actions #2

Updated by schlag _ over 9 years ago

yup, i didn't know what was relevant, so i pasted it all here. my initial attempt at installing was to do an 'apt-get install foreman' after setting up the apt list file. after running this 'dpkg --pending --configure', things seem to be considered installed at this point as i no longer get the postinst error when running 'apt-get -f install'.

export DEBUG=1
dpkg --pending --configure
Setting up ruby-foreman-salt (1.1.0) ...
+ . /usr/share/debconf/confmodule
+ [ ! ]
+ PERL_DL_NONLAZY=1
+ export PERL_DL_NONLAZY
+ [ ]
+ exec /usr/share/debconf/frontend /var/lib/dpkg/info/ruby-foreman-salt.postinst configure
+ . /usr/share/debconf/confmodule
+ [ ! 1 ]
+ [ -z ]
+ exec
+ [ ]
+ exec
+ DEBCONF_REDIR=1
+ export DEBCONF_REDIR
+ LOGFILE=/var/log/foreman-install.log
+ PLUGIN=foreman_salt
+ trap db_stop EXIT
+ BUNDLE=bundle
+ [ -h /usr/bin/foreman-ruby ]
+ BUNDLE=/usr/bin/foreman-ruby /usr/bin/bundle
+ cd /usr/share/foreman
+ [ ! -z 1 ]
+ /usr/bin/foreman-ruby /usr/bin/bundle show foreman_salt
+ /usr/bin/foreman-ruby /usr/bin/bundle install --local --no-prune
Could not find gem 'deface (< 1.0) ruby', which is required by gem 'foreman_salt (= 1.1.0) ruby', in any of the sources.
/usr/lib/ruby/vendor_ruby/bundler/resolver.rb:129:in `block in resolve'
/usr/lib/ruby/vendor_ruby/bundler/resolver.rb:127:in `catch'
/usr/lib/ruby/vendor_ruby/bundler/resolver.rb:127:in `resolve'
/usr/lib/ruby/vendor_ruby/bundler/definition.rb:192:in `resolve'
/usr/lib/ruby/vendor_ruby/bundler/definition.rb:127:in `specs'
/usr/lib/ruby/vendor_ruby/bundler/definition.rb:115:in `resolve_with_cache!'
/usr/lib/ruby/vendor_ruby/bundler/installer.rb:47:in `run'
/usr/lib/ruby/vendor_ruby/bundler/installer.rb:12:in `install'
/usr/lib/ruby/vendor_ruby/bundler/cli.rb:220:in `install'
/usr/lib/ruby/vendor_ruby/bundler/vendor/thor/task.rb:22:in `run'
/usr/lib/ruby/vendor_ruby/bundler/vendor/thor/invocation.rb:118:in `invoke_task'
/usr/lib/ruby/vendor_ruby/bundler/vendor/thor.rb:263:in `dispatch'
/usr/lib/ruby/vendor_ruby/bundler/vendor/thor/base.rb:386:in `start'
/usr/bin/bundle:13:in `<main>'
+ [ -f /usr/share/foreman/config/database.yml ]
+ [ ! -z 1 ]
+ /usr/sbin/foreman-rake db:migrate
Could not find gem 'foreman_salt (= 1.1.0) ruby' in the gems available on this machine.
Run `bundle install` to install missing gems.
+ true
+ /usr/sbin/foreman-rake db:seed
Could not find gem 'foreman_salt (= 1.1.0) ruby' in the gems available on this machine.
Run `bundle install` to install missing gems.
+ true
+ /usr/sbin/foreman-rake apipie:cache
Could not find gem 'foreman_salt (= 1.1.0) ruby' in the gems available on this machine.
Run `bundle install` to install missing gems.
+ true
+ chown -Rf foreman:foreman /usr/share/foreman
+ exit 0
+ db_stop
+ echo STOP

Actions #3

Updated by schlag _ over 9 years ago

hm, after updating /etc/default/foreman to START=yes, i am seeing this (which jives w/some of the errors in my prior update):

/etc/init.d/foreman start
/usr/lib/ruby/vendor_ruby/bundler/resolver.rb:287:in `resolve': Could not find gem 'foreman_salt (= 1.1.0) ruby' in the gems available on this machine. (Bundler::GemNotFound)
from /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:161:in `start'
from /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:128:in `block in resolve'
from /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:127:in `catch'
from /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:127:in `resolve'
from /usr/lib/ruby/vendor_ruby/bundler/definition.rb:192:in `resolve'
from /usr/lib/ruby/vendor_ruby/bundler/definition.rb:127:in `specs'
from /usr/lib/ruby/vendor_ruby/bundler/definition.rb:172:in `specs_for'
from /usr/lib/ruby/vendor_ruby/bundler/definition.rb:161:in `requested_specs'
from /usr/lib/ruby/vendor_ruby/bundler/environment.rb:23:in `requested_specs'
from /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:11:in `setup'
from /usr/lib/ruby/vendor_ruby/bundler.rb:107:in `setup'
from /usr/lib/ruby/vendor_ruby/bundler/setup.rb:17:in `<top (required)>'
from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'

Actions #4

Updated by Anonymous over 9 years ago

Thanks, I see the problem.

Also, please use foreman-installer like described on the website for setting up Foreman. There are many moving parts around Foreman itself and the installer is taking care of setting all these up accordingly. One thing is that foreman (and if wanted also the puppet master) is running under passenger/apache. Be aware that this will overwrite some of your configs, e.g. apache, so it's best to have a dedicated, clean box.

If you want only salt and no puppet, I'd recommend to use "foreman-installer -i" and deselect the parts you don't need.

Actions #5

Updated by Anonymous over 9 years ago

Could you try to install foreman_salt from http://stagingdeb.theforeman.org/pool/plugins/mmoll/r/ruby-foreman-salt/ruby-foreman-salt_9999-plugin+scratchbuild+201412291854_all.deb ? It should depend on ruby-foreman-deface now, which is available from the plugins repo.

Actions #6

Updated by Anonymous over 9 years ago

  • Tracker changed from Support to Bug
  • Project changed from Salt to Packaging
  • Category set to Debian/Ubuntu
  • Status changed from Assigned to Ready For Testing
  • Difficulty set to trivial
  • Pull request https://github.com/theforeman/foreman-packaging/pull/477 added
Actions #7

Updated by Dominic Cleal over 9 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

Built to nightly and 1.7 plugin repos.

Actions

Also available in: Atom PDF