summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--puppet/modules/leap/manifests/cli/install.pp16
-rwxr-xr-xtests/example-provider/vagrant/configure-leap.sh7
-rwxr-xr-xtests/example-provider/vagrant/install-platform.pp3
-rw-r--r--tests/example-provider/vagrant/vagrant.config2
4 files changed, 12 insertions, 16 deletions
diff --git a/puppet/modules/leap/manifests/cli/install.pp b/puppet/modules/leap/manifests/cli/install.pp
index 25e87033..d009316b 100644
--- a/puppet/modules/leap/manifests/cli/install.pp
+++ b/puppet/modules/leap/manifests/cli/install.pp
@@ -1,13 +1,20 @@
# installs leap_cli on node
class leap::cli::install ( $source = false ) {
+
+ # nokogiri is a dependency gem of leap_cli and
+ # needs build tools in order to get compiled
+ ensure_packages (['gcc', 'make', 'zlib1g-dev'])
+ class { '::ruby':
+ install_dev => true,
+ require => [ Package['gcc'], Package['make'], Package['zlib1g-dev'] ]
+ }
+
+
if $source {
# needed for building leap_cli from source
include ::git
include ::rubygems
- class { '::ruby':
- install_dev => true
- }
class { 'bundler::install': install_method => 'package' }
@@ -40,7 +47,8 @@ class leap::cli::install ( $source = false ) {
else {
package { 'leap_cli':
ensure => installed,
- provider => gem
+ provider => gem,
+ require => Class['ruby']
}
}
}
diff --git a/tests/example-provider/vagrant/configure-leap.sh b/tests/example-provider/vagrant/configure-leap.sh
index fd34d7ea..8bd591e0 100755
--- a/tests/example-provider/vagrant/configure-leap.sh
+++ b/tests/example-provider/vagrant/configure-leap.sh
@@ -35,10 +35,6 @@ echo '{ "webapp": { "admins": ["testadmin"] } }' > services/webapp.json
$LEAP $OPTS compile
-$GIT init
-$GIT add .
-$GIT commit -m'configured provider'
-
$LEAP $OPTS node init $NODE
if [ $? -eq 1 ]; then
echo 'node init failed'
@@ -52,9 +48,6 @@ gem install rake
$LEAP $OPTS -v 2 deploy
-$GIT add .
-$GIT commit -m'initialized and deployed provider'
-
# Vagrant: leap_mx fails to start on jessie
# https://leap.se/code/issues/7755
# Workaround: we stop and start leap-mx after deploy and
diff --git a/tests/example-provider/vagrant/install-platform.pp b/tests/example-provider/vagrant/install-platform.pp
index 223853c1..9cefcf7c 100755
--- a/tests/example-provider/vagrant/install-platform.pp
+++ b/tests/example-provider/vagrant/install-platform.pp
@@ -10,6 +10,3 @@ class { '::leap::cli::install':
file { [ '/srv/leap', '/srv/leap/configuration', '/var/log/leap' ]:
ensure => directory
}
-
-# install prerequisites for configuring the provider
-include ::git
diff --git a/tests/example-provider/vagrant/vagrant.config b/tests/example-provider/vagrant/vagrant.config
index 60d2a52c..ff5dd38f 100644
--- a/tests/example-provider/vagrant/vagrant.config
+++ b/tests/example-provider/vagrant/vagrant.config
@@ -19,5 +19,3 @@ SUDO="sudo -u ${USER}"
PROVIDERDIR="/home/${USER}/leap/configuration"
PLATFORMDIR="/srv/leap_platform"
LEAP="$SUDO /usr/local/bin/leap"
-GIT="$SUDO git"
-