fix(ci): reduce staging validation log output#29
Merged
Conversation
Suppress successful staging health and character-list response bodies in Actions logs. The character smoke still validates the API code and fails on unexpected responses, but no longer prints the full public character list on success. Verification: - bash -n scripts/validate-staging-host.sh - git diff --check - simulated staging validation with fake docker/curl commands
There was a problem hiding this comment.
Pull request overview
Reduces noise (and potential data exposure) in GitHub Actions staging validation by suppressing successful curl response bodies and replacing them with concise ok status lines, while adding an API-code check for the character list smoke test.
Changes:
- Suppress
/api/healthresponse body output and print a concise success message. - Capture
/api/open/character/listresponse to a temp file instead of logging it. - Add a smoke validation step that checks the API response
codeand prints truncated output only on failure.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| echo "==> staging character list smoke" | ||
| curl -fsS "http://127.0.0.1:9009/api/open/character/list?pageNum=1&pageSize=2" | ||
| curl -fsS -o "$CHARACTER_LIST_RESPONSE" "http://127.0.0.1:9009/api/open/character/list?pageNum=1&pageSize=2" | ||
| if ! grep -q '"code":200' "$CHARACTER_LIST_RESPONSE"; then |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
okmessages on successful validation.Why
The deploy was successful, but
scripts/validate-staging-host.shusedcurl -fsSwithout-o, so the full/api/open/character/listJSON response was written to the Actions log. That is noisy and can expose unnecessary public data/URLs.Verification
bash -n scripts/validate-staging-host.shgit diff --checkdockerandcurl; output only showed compose status plus conciseoklines.