From 097a4de74391961d7873465470ff54c20917491e Mon Sep 17 00:00:00 2001 From: Sergii Kipot Date: Tue, 9 Feb 2016 12:36:43 +0100 Subject: [PATCH] MT#17213 Add two-staged puppet run In some cases puppet should be restarted in order to catch up with system changes it did itself. For instance if ldap is installed in puppet session new users won't be available for puppet in the same session. With this change we have flexibility to run puppet first just to insall core utils and then do a second normal run. Change-Id: I7f8d9a7cb45ddcf6c32fd836a4cc488f572092c8 --- deployment.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/deployment.sh b/deployment.sh index 4097633..a552712 100755 --- a/deployment.sh +++ b/deployment.sh @@ -2195,6 +2195,8 @@ check_puppet_rc () { jessie|stretch) grml-chroot $TARGET puppet agent --enable 2>&1 | tee -a /tmp/puppet.log check_puppet_rc "${PIPESTATUS[0]}" "0" + grml-chroot $TARGET puppet agent --test --tags core --waitforcert 30 2>&1 | tee -a /tmp/puppet.log + check_puppet_rc "${PIPESTATUS[0]}" "2" grml-chroot $TARGET puppet agent --test --waitforcert 30 2>&1 | tee -a /tmp/puppet.log check_puppet_rc "${PIPESTATUS[0]}" "2" ;;