From 73d6006ff57a1c3eea6732bb40cb945d68d90040 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Sat, 5 Mar 2016 22:37:38 -0300 Subject: Deploy: dependencies in a single place --- bin/dependencies | 11 ++++++++++- bin/deploy | 3 +-- 2 files changed, 11 insertions(+), 3 deletions(-) (limited to 'bin') diff --git a/bin/dependencies b/bin/dependencies index 507145b..94d3765 100755 --- a/bin/dependencies +++ b/bin/dependencies @@ -3,6 +3,15 @@ # Puppet bootstrap dependencies. # +# Parameters +DEPENDENCIES="puppet-common git mr whois" +DEPLOY_DEPENDENCIES="ruby-sqlite3 ruby-activerecord" + +# Additional non-wheezy package +if [ "`head -c 1 /etc/debian_version`" != '7' ]; then + DEPLOY_DEPENDENCIES="$DEPLOY_DEPENDENCIES ruby-activerecord-deprecated-finders" +fi + # Install a package, thanks to the Hydra Suite. function provision_package { if [ -z "$1" ]; then @@ -23,6 +32,6 @@ if [ "`whoami`" != 'root' ]; then fi # Ensure basic packages are installed. -for package in puppet git mr whois; do +for package in $DEPENDENCIES; do provision_package $package done diff --git a/bin/deploy b/bin/deploy index 6088edb..9c5fbce 100755 --- a/bin/deploy +++ b/bin/deploy @@ -6,7 +6,6 @@ # Parameters DIRNAME="`dirname $0`" BASEDIR="$DIRNAME/.." -DEPLOY_DEPENDENCIES="puppet ruby-sqlite3 ruby-activerecord ruby-activerecord-deprecated-finders" # Determine hostname if [ ! -z "$1" ]; then @@ -23,7 +22,7 @@ fi # Check manifest if [ ! -e "$PUPPET_MANIFEST" ]; then - echo "no manifest found for $FQDN" + echo "No manifest found for $FQDN" exit 1 fi -- cgit v1.2.3