Merge branch 'develop' into dist/eole/2.7.0/develop

This commit is contained in:
vincent 2019-02-25 10:55:02 +01:00
commit b6cbb6d9df
1 changed files with 7 additions and 8 deletions

View File

@ -108,25 +108,24 @@ if [ "$(CreoleGet activer_one_ha)" = "oui" ] && [ "$(CreoleGet one_ha_server_ind
else else
follower=1 follower=1
fi fi
for ((i = 0; i < ${#HAPY_SLV[*]}; i +=1)) for host in ${HAPY_SLV}; do
do
echo -e "\n" echo -e "\n"
EchoOrange "Traitement du noeud ${HAPY_SLV[${i}]}" EchoOrange "Traitement du noeud ${host}"
echo echo
EchoVert " * Gestion des clés SSH" EchoVert " * Gestion des clés SSH"
echo echo
copy_ssh_id ${HAPY_SLV[${i}]} copy_ssh_id ${host}
[[ ${?} -ne 0 ]] && EchoRouge "Erreur lors de l'échange de clés SSH avec le noeud ${HAPY_SLV[${i}]}}" [[ ${?} -ne 0 ]] && EchoRouge "Erreur lors de l'échange de clés SSH avec le noeud ${host}"
if [ $follower = 0 ]; then if [ $follower = 0 ]; then
continue continue
fi fi
EchoVert " * Enregistrement du noeud" EchoVert " * Enregistrement du noeud"
register_node ${HAPY_SLV[${i}]} register_node ${host}
wait_node_ok ${HAPY_SLV[${i}]} wait_node_ok ${host}
if [[ ${?} -ne 0 ]] if [[ ${?} -ne 0 ]]
then then
EchoRouge "Erreur lors de l'enregistrement du noeud ${HAPY_SLV[${i}]} !" EchoRouge "Erreur lors de l'enregistrement du noeud ${host} !"
fi fi
done done