summaryrefslogtreecommitdiff
path: root/puppet/bin/deploy
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2017-10-23 19:43:47 -0200
committerSilvio Rhatto <rhatto@riseup.net>2017-10-23 19:43:47 -0200
commitb45c60df8af294fe97b8912a0b9703c76e5de8d6 (patch)
tree2a3442f2e0b3c7494cc591ac8c8053d84c3c9d84 /puppet/bin/deploy
parentc880b15f013c6d761e4632570112f796ffc1dcda (diff)
parent1bfffe2e0adff6e44ec33726988b64f95ea2f599 (diff)
downloaddebian-b45c60df8af294fe97b8912a0b9703c76e5de8d6.tar.gz
debian-b45c60df8af294fe97b8912a0b9703c76e5de8d6.tar.bz2
Merge commit '1bfffe2e0adff6e44ec33726988b64f95ea2f599' into develop
Diffstat (limited to 'puppet/bin/deploy')
-rwxr-xr-xpuppet/bin/deploy14
1 files changed, 9 insertions, 5 deletions
diff --git a/puppet/bin/deploy b/puppet/bin/deploy
index 5d3361b..22065dc 100755
--- a/puppet/bin/deploy
+++ b/puppet/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
@@ -15,10 +14,15 @@ else
FQDN="`cat /etc/hostname`"
fi
-# Check for manifest
-PUPPET_MANIFEST="$BASEDIR/puppet/manifests/nodes/$FQDN.pp"
+# Set manifest
+PUPPET_MANIFEST="$BASEDIR/manifests/nodes/$FQDN.pp"
if [ ! -e "$PUPPET_MANIFEST" ]; then
- echo "file not found: $PUPPET_MANIFEST"
+ PUPPET_MANIFEST="$BASEDIR/manifests/nodes/default.pp"
+fi
+
+# Check manifest
+if [ ! -e "$PUPPET_MANIFEST" ]; then
+ echo "No manifest found for $FQDN"
exit 1
fi
@@ -54,5 +58,5 @@ if [ -d "$BASEDIR/puppet/files/patches/$DIST" ]; then
fi
# Run puppet apply
-PUPPET_OPTS="--confdir=$BASEDIR/puppet --modulepath=$BASEDIR/puppet/modules"
+PUPPET_OPTS="--confdir=$BASEDIR --modulepath=$BASEDIR/modules"
LC_ALL=C $SUDO puppet apply $PUPPET_OPTS $PUPPET_MANIFEST