aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.md1
-rwxr-xr-xshare/templater/puppet/setup6
2 files changed, 6 insertions, 1 deletions
diff --git a/README.md b/README.md
index 93c2d3b..33560f5 100644
--- a/README.md
+++ b/README.md
@@ -28,7 +28,6 @@ Create the project (requires [KVMX](https://kvmx.fluxo.info)):
Basic puppet configuration:
- cp puppet/config/node/box.example.org.yaml puppet/config/node/drupal8.example.org.yaml
vim puppet/config/node/drupal8.example.org.yaml # set nodo::role to 'dev::drupal8'
Edit your drupal config
diff --git a/share/templater/puppet/setup b/share/templater/puppet/setup
index b71fbdb..5821ae7 100755
--- a/share/templater/puppet/setup
+++ b/share/templater/puppet/setup
@@ -5,6 +5,7 @@
# Parameters
SHARE="$1"
+PROJECT="`pwd`"
BOOTSTRAP="https://git.fluxo.info/puppet-bootstrap"
# Include basic functions
@@ -30,6 +31,11 @@ function templater_puppet {
#git submodule add $BOOSTRAP puppet
git remote add puppet $BOOTSTRAP
git subtree add --prefix puppet $BOOTSTRAP master --squash
+
+ # Setup node config
+ if [ -e "puppet/config/node/box.example.org.yaml" ]; then
+ cp puppet/config/node/box.example.org.yaml puppet/config/node/$PROJECT.example.org.yaml
+ fi
else
__templater_echo "Puppet already set"
fi