Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: update workflows logic. #2688

Merged
merged 4 commits into from
Sep 29, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 28 additions & 28 deletions .github/workflows/publish-docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,34 +63,34 @@ jobs:
docker compose up -d
sleep 60

- name: Check openim-server health
run: |
timeout=300
interval=30
elapsed=0
while [[ $elapsed -le $timeout ]]; do
if ! docker exec openim-server mage check; then
echo "openim-server is not ready, waiting..."
sleep $interval
elapsed=$(($elapsed + $interval))
else
echo "Health check successful"
exit 0
fi
done
echo "Health check failed after 5 minutes"
exit 1

- name: Check openim-chat health
if: success()
run: |
if ! docker exec openim-chat mage check; then
echo "openim-chat check failed"
exit 1
else
echo "Health check successful"
exit 0
fi
# - name: Check openim-server health
# run: |
# timeout=300
# interval=30
# elapsed=0
# while [[ $elapsed -le $timeout ]]; do
# if ! docker exec openim-server mage check; then
# echo "openim-server is not ready, waiting..."
# sleep $interval
# elapsed=$(($elapsed + $interval))
# else
# echo "Health check successful"
# exit 0
# fi
# done
# echo "Health check failed after 5 minutes"
# exit 1

# - name: Check openim-chat health
# if: success()
# run: |
# if ! docker exec openim-chat mage check; then
# echo "openim-chat check failed"
# exit 1
# else
# echo "Health check successful"
# exit 0
# fi


- name: Extract metadata for Docker # (tags, labels)
Expand Down
Loading