Test ntfy
This commit is contained in:
parent
34883486cf
commit
52d2a96b13
@ -112,23 +112,6 @@ jobs:
|
||||
if: always()
|
||||
|
||||
steps:
|
||||
- name: Wait for ntfy service to be healthy
|
||||
run: |
|
||||
ssh -o StrictHostKeyChecking=no $SERVER_USER@$SERVER_IP '
|
||||
echo "Waiting for ntfy container..."
|
||||
for i in {1..30}; do
|
||||
STATUS=$(docker inspect --format="{{json .State.Health.Status }}" ntfy)
|
||||
if [[ $STATUS == "\"healthy\"" ]]; then
|
||||
echo "ntfy is healthy!"
|
||||
exit 0
|
||||
fi
|
||||
echo "ntfy not ready yet ($STATUS). Retrying..."
|
||||
sleep 2
|
||||
done
|
||||
echo "Error: ntfy did not become healthy in time."
|
||||
exit 1
|
||||
'
|
||||
|
||||
- name: Notify ntfy
|
||||
run: |
|
||||
STATUS="${{ needs.deploy.result }}"
|
||||
@ -140,7 +123,7 @@ jobs:
|
||||
MSG="❌ Costco App Deployment FAILED: $IMAGE_NAME:${{ github.sha }}"
|
||||
fi
|
||||
|
||||
curl -d "🚀 Deployment successful: $IMAGE_NAME:$GITHUB_SHA" \
|
||||
curl -d "$MSG" \
|
||||
https://ntfy.nicosaya.com/gitea
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user