container-puppet.sh idempotency on restart

When restarting a container-puppet-{service} container,
make sure to remove /etc/puppet from its storage,
otherwise the config generation might fail, for example
when using upload-puppet-module with a stack update.

Change-Id: I1ff3363259397bba60f5ec09086cb7de34e7af8b
Closes-Bug: #1940571
This commit is contained in:
Damien Ciabrini
2021-08-19 22:07:31 +02:00
parent cae34beb9c
commit 2e4361c878

View File

@@ -13,6 +13,7 @@
set -e
[ "$DEBUG" = "false" ] || set -x
rm -rf /etc/puppet
mkdir -p /etc/puppet
cp -dR /tmp/puppet-etc/* /etc/puppet
rm -Rf /etc/puppet/ssl # not in use and causes permission errors