salt.sh: Use salt-call to apply linux sls on cfg01 67/49167/1
authorAlexandru Avadanii <Alexandru.Avadanii@enea.com>
Mon, 18 Dec 2017 03:39:01 +0000 (04:39 +0100)
committerAlexandru Avadanii <Alexandru.Avadanii@enea.com>
Mon, 18 Dec 2017 03:39:01 +0000 (04:39 +0100)
Also, retry applying linux high state up to twice, due to rare
spurious failures with 'No reponse' status.

Change-Id: Ic7839a5c9501673cb127412136afb91e05f87a7e
Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
mcp/scripts/salt.sh

index 25eb0ed..d687e3e 100755 (executable)
@@ -97,7 +97,7 @@ ssh ${SSH_OPTS} "${SSH_SALT}" bash -s -e << SALT_INSTALL_END
   salt -C "${NODE_MASK} or cfg01*" state.apply salt | \
     grep -Fq 'No response' && salt -C "${NODE_MASK} or cfg01*" state.apply salt
 
-  salt -C 'I@salt:master' state.sls linux
+  salt-call state.sls linux || salt-call state.sls linux
   salt -C "${NODE_MASK} and not cfg01*" state.sls linux || true
   salt -C "${NODE_MASK} and not cfg01*" pkg.upgrade refresh=False