summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xshare/hydractl/deploy9
1 files changed, 7 insertions, 2 deletions
diff --git a/share/hydractl/deploy b/share/hydractl/deploy
index 450c92f..d61519e 100755
--- a/share/hydractl/deploy
+++ b/share/hydractl/deploy
@@ -20,6 +20,11 @@
source $APP_BASE/lib/hydra/functions || exit 1
hydra_config_load
+# Parameters
+MANIFEST="`facter fqdn`.pp"
+
# Run puppet
-sudo puppet apply --confdir=$HYDRA_FOLDER/puppet \
- --modulepath=$HYDRA_FOLDER/modules $HYDRA_FOLDER/puppet/manifests/nodes/$(facter fqdn).pp
+if [ -e "$HYDRA_FOLDER/puppet/manifests/nodes/$MANIFEST" ]; then
+ sudo puppet apply --confdir=$HYDRA_FOLDER/puppet \
+ --modulepath=$HYDRA_FOLDER/modules $HYDRA_FOLDER/puppet/manifests/nodes/$MANIFEST
+fi