diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2015-09-11 11:09:00 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2015-09-11 11:09:00 -0300 |
commit | 2b6bf9b364e05f610709b32598232f4b5c2e92a5 (patch) | |
tree | d17a1e87cf6d7496f0dd8df094c4148f3473e7dc | |
parent | c3ddbeb7b3cde2174169cb29f25e6f1a1d978395 (diff) | |
download | hydra-2b6bf9b364e05f610709b32598232f4b5c2e92a5.tar.gz hydra-2b6bf9b364e05f610709b32598232f4b5c2e92a5.tar.bz2 |
Saner defaults for puppet deployment
-rwxr-xr-x | share/hydra/deploy | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/share/hydra/deploy b/share/hydra/deploy index 5904f5d..0c01623 100755 --- a/share/hydra/deploy +++ b/share/hydra/deploy @@ -32,13 +32,20 @@ fi for node in $NODES; do echo "Deploying to $node..." + # Saner defaults + $HYDRA_CONNECT $node sudo mkdir -p /etc/puppet + $HYDRA_CONNECT $node sudo chown -R root. /etc/puppet + $HYDRA_CONNECT $node sudo chmod -R 640 /etc/puppet + # Sync repository to server - rsync -rlptD --delete --remote-rsync "sudo rsync" $HYDRA_FOLDER/puppet/ $node:/etc/puppet/ + # Exclude eventual keys and version control files + rsync -CrltDv --no-perms --exclude=keys --delete --remote-rsync "sudo rsync" $HYDRA_FOLDER/puppet/ $node:/etc/puppet/ # Run puppet $HYDRA_CONNECT $node <<EOF ##### BEGIN REMOTE SCRIPT ##### sudo chown -R root. /etc/puppet + sudo chmod -R 640 /etc/puppet sudo puppet apply /etc/puppet/manifests/nodes/\$(facter fqdn).pp ##### END REMOTE SCRIPT ####### EOF |