Skip to content

Commit

Permalink
chore: deprecated GitHub Jobs summary write
Browse files Browse the repository at this point in the history
  • Loading branch information
cybersokari committed Dec 6, 2024
1 parent 7804d56 commit c9590f1
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 25 deletions.
1 change: 0 additions & 1 deletion .github/workflows/actions-example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ jobs:
-e WEBSITE_EXPIRES=${{ github.event.inputs.website-expires }} \
-e KEEP_RETRIES=${{ github.event.inputs.keep-retries }} \
-e KEEP_HISTORY=${{ github.event.inputs.keep-history }} \
-v $GITHUB_STEP_SUMMARY:/github/summary.txt \
-v {{ github.workspace }}/assets/allure-results:/allure-results \
-v ${{ github.workspace }}/gcp-key.json:/credentials/gcp-key.json \
sokari/allure-docker-deploy:latest
12 changes: 5 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ jobs:
-e KEEP_HISTORY=true \
-e KEEP_RETRIES=true \
-e GITHUB=true
# -v $GITHUB_STEP_SUMMARY:/github/summary.txt \
-v ${{ github.workspace }}/allure-results:/allure-results \
-v ${{ secrets.GCP_CREDENTIALS_FILE_PATH }}:/credentials/gcp-key.json \
sokari/allure-docker-deploy:latest
Expand All @@ -59,7 +58,6 @@ jobs:
Tips:
1. Use a different value `WEBSITE_ID` in every test run. `${{ github.ref }}` is a good example.
2. Set the WEBSITE_EXPIRES value appropriately to deallocate old test run sites.
3. Mount the `$GITHUB_STEP_SUMMARY` file to see your test report URL in GitHub Actions job summary
### Local test runs
#### Step 1: Pull the Docker Image
```bash
Expand Down Expand Up @@ -152,11 +150,11 @@ Nevertheless, you have free 5GB of storage before you will incur any charges_
---

## Where to find your hosted test report URL
| Platform | Report URL output location |
|-----------|----------------------------------------------------|
| GitHub | Logs, Firebase console, GitHub Actions job summary |
| Gitlab | Logs, Firebase console |
| Localhost | Logs, Firebase console |
| Platform | Report URL output location |
|-----------|-------------------------------------|
| GitHub | Logs, Firebase console, Slack (WIP) |
| Gitlab | Logs, Firebase console, Slack (WIP) |
| Localhost | Logs, Firebase console |
### URL in logs example
<div style="text-align: left"><img src="assets/ci-report-url-ss.png" height="220" alt="Firebase CLI console output"></div>

Expand Down
6 changes: 0 additions & 6 deletions start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,6 @@ if [ ! -d "$MOUNT_POINT" ]; then
exit 1
fi

GITHUB_SUMMARY_FILE="/github/summary.txt"
if [ ! -d "$GITHUB_SUMMARY_FILE" ]; then
export GITHUB_SUMMARY_FILE
echo "Git summary file directory mounted"
fi

if [ -n "$TTL_SECS" ]; then
if ! [[ "$TTL_SECS" -eq "$TTL_SECS" && "$TTL_SECS" -ge 0 ]]; then
echo "Error: $TTL_SECS must be a positive number"
Expand Down
11 changes: 0 additions & 11 deletions worker/app/site-builder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,17 +83,6 @@ async function publishToFireBaseHosting() {
if (match && match[2]) {
const url = match[2]
console.log(`Allure test report URL: ${url}`)
const githubSummaryFile = process.env.GITHUB_SUMMARY_FILE
if (githubSummaryFile) { // Add URL to GitHub workflow summary
builder.clear()
builder.append(`echo "Allure test report URL :globe_with_meridians: : ${url}"`).append(' ')
.append('>>').append(' ').append(`${githubSummaryFile}`)
try {
await exec(builder.toString())
} catch (e) {
console.warn('Failed to write site URL to GitHub job summary')
}
}
} else {
console.warn('Could not parse URL from hosting.')
console.log(stdout)
Expand Down

0 comments on commit c9590f1

Please sign in to comment.