diff options
Diffstat (limited to 'share')
-rwxr-xr-x | share/hydra/deploy | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/share/hydra/deploy b/share/hydra/deploy index e55e545..38d8bcb 100755 --- a/share/hydra/deploy +++ b/share/hydra/deploy @@ -49,7 +49,7 @@ for node in $NODES; do # Setup deploy environment FOLDER=$node - hydra_deploy_setup folder $FOLDER + hydra_deploy_setup folder $FOLDER || continue # Check if puppet is installed if [ ! -e "$FOLDER/usr/bin/puppet" ]; then @@ -78,7 +78,7 @@ for node in $NODES; do echo "Deploying to localhost..." # Setup deploy environment - hydra_deploy_setup + hydra_deploy_setup || continue # Ensure key availability hydra $HYDRA eyaml $FQDN @@ -99,7 +99,7 @@ for node in $NODES; do echo "Deploying to $node..." # Setup deploy environment - hydra_deploy_setup remote $node + hydra_deploy_setup remote $node || continue # Check if puppet is installed $HYDRA_CONNECT $FQDN <<EOF @@ -115,24 +115,30 @@ EOF # Check connection if [ "$?" != "0" ]; then echo "Error connecting or setting up $FQDN." - exit 1 + continue fi # Create folders hydra_deploy_mkdirs # Collect facts - hydra_deploy_facts_collect remote + hydra_deploy_facts_collect remote || continue # Sync repository to server echo "Syncing configuration..." $DEPLOY_RSYNC "$RSYNC_PATH" $DEPLOY_OPTS + # Check connection + if [ "$?" != "0" ]; then + echo "Error syncing to $FQDN." + continue + fi + # Copy keys - hydra_deploy_copy_keys remote + hydra_deploy_copy_keys remote || continue # Copy configuration - hydra_deploy_copy_secrets remote + hydra_deploy_copy_secrets remote || continue # Run puppet echo "Applying configuration..." |