From 877d93bb84f7efb06786f43f582f894f143acf20 Mon Sep 17 00:00:00 2001 From: Ian Wienand Date: Thu, 18 Jun 2015 14:04:15 +1000 Subject: [PATCH] Remove cloud-init details If we have booted with cloud-init, then this status directory is populated. Remove it so when we boot snapshot images, they behave as if on a fresh system. Change-Id: Idc9ce01290b659e3239d30be847221447a8e5e84 --- nodepool/scripts/prepare_node.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/nodepool/scripts/prepare_node.sh b/nodepool/scripts/prepare_node.sh index e1a5b1f0aa..ff5fd33014 100755 --- a/nodepool/scripts/prepare_node.sh +++ b/nodepool/scripts/prepare_node.sh @@ -182,6 +182,9 @@ datasource_list: [ ConfigDrive, None ] EOF fi +# reset cloud-init +sudo rm -rf /var/lib/cloud/instances + sudo bash -c "echo 'include: /etc/unbound/forwarding.conf' >> /etc/unbound/unbound.conf" if [ -e /etc/init.d/unbound ] ; then sudo /etc/init.d/unbound restart