diff options
Diffstat (limited to 'modules/base_installation/files/scripts/puppet_reset_and_apply')
-rw-r--r-- | modules/base_installation/files/scripts/puppet_reset_and_apply | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/modules/base_installation/files/scripts/puppet_reset_and_apply b/modules/base_installation/files/scripts/puppet_reset_and_apply new file mode 100644 index 0000000..ff71aa8 --- /dev/null +++ b/modules/base_installation/files/scripts/puppet_reset_and_apply | |||
@@ -0,0 +1,14 @@ | |||
1 | #!/bin/bash | ||
2 | |||
3 | cd /etc/puppetlabs/code | ||
4 | git fetch origin | ||
5 | |||
6 | branch="master" | ||
7 | if [ -n "$1" ]; then | ||
8 | branch="$1" | ||
9 | fi | ||
10 | |||
11 | git reset --hard origin/$1 | ||
12 | |||
13 | git submodule update --init | ||
14 | puppet apply --test manifests/site.pp | ||