summaryrefslogtreecommitdiff
path: root/puppet/bin/deploy
diff options
context:
space:
mode:
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