diff --git a/ansible/sbin/update_images b/ansible/sbin/update_images index dd73e12..8e0c507 100755 --- a/ansible/sbin/update_images +++ b/ansible/sbin/update_images @@ -23,7 +23,7 @@ ls /var/lib/risotto/images_files/ | while read image; do if [ -d /var/lib/risotto/images_files/"$image" ]; then echo echo "Install image $image" | tee -a /var/log/risotto/update_images.log - /usr/local/sbin/build_image "$image" | tee -a /var/log/risotto/update_images.log || (echo "PROBLEME" | tee -a /var/log/risotto/update_images.log; true) + /usr/local/sbin/build_image "$image" || echo "PROBLEME" | tee -a /var/log/risotto/update_images.log fi done @@ -61,7 +61,7 @@ for nspawn in $(ls /etc/systemd/nspawn/*.nspawn); do sleep 1 done fi - if [ ! -d "$MACHINE_MACHINES_DIR" ]; then + if [ ! -d "$MACHINE_MACHINES_DIR/etc" ]; then rm -f "$VERSION_MACHINE" fi diff -q "$RISOTTO_IMAGE_DIR/$IMAGE_NAME_RISOTTO_IMAGE_NAME".version "$VERSION_MACHINE" &> /dev/null || (