fix: ajoute la gestion d'erreur au script de rebuild cron
This commit is contained in:
parent
1bc75fc2f0
commit
273ba0c410
1 changed files with 8 additions and 2 deletions
|
|
@ -4,7 +4,13 @@ if [[ "$INSTANCE_NUMBER" != "0" ]]; then
|
|||
exit 0
|
||||
fi
|
||||
|
||||
curl -X POST \
|
||||
if [[ -z "$REBUILD_API_TOKEN" ]]; then
|
||||
echo "REBUILD_API_TOKEN non défini" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
curl -sf -X POST \
|
||||
"https://api-bridge.clever-cloud.com/v2/organisations/${CC_OWNER_ID}/applications/${APP_ID}/instances" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d "{\"token\": \"${REBUILD_API_TOKEN}\"}"
|
||||
-d "{\"token\": \"${REBUILD_API_TOKEN}\"}" \
|
||||
|| echo "Rebuild failed" >&2
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue