diff --git a/.woodpecker.yml b/.woodpecker.yml index 442b2ba..15fe260 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -84,12 +84,15 @@ steps: # acme.sh est idempotent : skip si cert valide, renouvelle si proche expiration # Exit 0 = emis/renouvele, exit 2 = skip (domaine inchange), autres = erreur # --home /etc/acme.sh = volume persistant sonic_acme (sinon /root/.acme.sh non persiste) + # ; ACME_EXIT=$? ne fonctionne pas avec set -e (shell quitte si exit != 0 avant la capture) + # || ACME_EXIT=$? capture le code sans declencher set -e + ACME_EXIT=0 docker exec sonic-acme-1 /app/acme.sh \ --home /etc/acme.sh \ --issue -d "$DOMAIN" \ --webroot /usr/share/nginx/html \ --server letsencrypt \ - --accountemail support+acme@asycn.io; ACME_EXIT=$? + --accountemail support+acme@asycn.io || ACME_EXIT=$? if [ "$ACME_EXIT" -ne 0 ] && [ "$ACME_EXIT" -ne 2 ]; then echo "ERREUR: acme.sh a echoue (exit $ACME_EXIT)" exit 1