-
Notifications
You must be signed in to change notification settings - Fork 237
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
Add ZO release #2605
Add ZO release #2605
Conversation
WalkthroughThe changes primarily involve updating multiple GitHub Actions workflows across various repositories to introduce two new parameters: Changes
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
[zzz-frontend] [Fri Jan 24 00:13:51 UTC 2025] - Deployed ef49ab3 to https://genshin-optimizer-prs.github.io/pr/2605/zzz-frontend (Takes 3-5 minutes after this completes to be available) [sr-frontend] [Fri Jan 24 00:14:57 UTC 2025] - Deployed ef49ab3 to https://genshin-optimizer-prs.github.io/pr/2605/sr-frontend (Takes 3-5 minutes after this completes to be available) [Fri Jan 24 01:48:29 UTC 2025] - Deleted deployment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (2)
.github/workflows/new-zo-release.yml (1)
1-5
: Consider adding concurrency configuration
If multiple releases can be triggered in parallel, adding a concurrency group under theon
orjobs
section will help avoid collisions..github/workflows/build-frontend.yml (1)
15-22
: Validate or provide fallback defaults for new inputs.
Providing these inputs as required is helpful; however, consider adding validation steps or fallback defaults to handle potential misconfigurations in external calls.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (9)
.github/workflows/beta-go-release.yml
(1 hunks).github/workflows/beta-sro-release.yml
(1 hunks).github/workflows/beta-zo-release.yml
(1 hunks).github/workflows/build-frontend.yml
(3 hunks).github/workflows/build-go-next-pr.yml
(1 hunks).github/workflows/build-sro-pr.yml
(1 hunks).github/workflows/build-zo-pr.yml
(1 hunks).github/workflows/deploy-frontend.yml
(2 hunks).github/workflows/new-zo-release.yml
(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
- GitHub Check: lint
- GitHub Check: call-build / build
- GitHub Check: call-build / build
🔇 Additional comments (13)
.github/workflows/new-zo-release.yml (1)
6-14
: Verify repository variable and secret usage
Ensure${{ vars.ZO_REPO }}
is defined as a repository variable and'ZO_REPO_SSH_KEY'
is set as a repository secret. Otherwise, deployments will fail at checkout..github/workflows/beta-go-release.yml (1)
19-20
: Confirm that PR_REPO variable and PR_REPO_SSH_KEY secret are correctly configured
These new parameters require${{ vars.PR_REPO }}
and the'PR_REPO_SSH_KEY'
secret. Missing or misconfigured values can cause the build to fail when checking out the target repo..github/workflows/beta-zo-release.yml (1)
19-20
: Validate environment references for repo_name and repo_deploy_secret_name
Ensure${{ vars.PR_REPO }}
is a valid repository variable and'PR_REPO_SSH_KEY'
is properly set as a secret. This alignment is essential for the workflow to run without checkout or deployment errors..github/workflows/beta-sro-release.yml (1)
19-20
: Double-check PR_REPO and PR_REPO_SSH_KEY definitions
The new parametersrepo_name
andrepo_deploy_secret_name
depend on${{ vars.PR_REPO }}
and'PR_REPO_SSH_KEY'
. Confirm they are present and correctly configured in the repository..github/workflows/build-zo-pr.yml (1)
28-29
: Confirm usage of new variables in the build job
Providingrepo_name
andrepo_deploy_secret_name
requires${{ vars.PR_REPO }}
and'PR_REPO_SSH_KEY'
to be valid. Missing them can break the build or deployment steps..github/workflows/build-sro-pr.yml (1)
28-29
: Ensure the environment variable and secret are defined.
You’re referencingvars.PR_REPO
and using a literal'PR_REPO_SSH_KEY'
. IfPR_REPO
is missing or the secret doesn't exist, this step will fail.As a follow-up, consider verifying references to
PR_REPO
andPR_REPO_SSH_KEY
across the repo:.github/workflows/build-go-next-pr.yml (1)
29-30
: Validate usage of repo variables and secrets.
Similarly to the SRO workflow, ensurevars.PR_REPO
and'PR_REPO_SSH_KEY'
exist and point to valid resources for this specific environment.✅ Verification successful
Variables are properly configured and follow established patterns
The usage ofvars.PR_REPO
andPR_REPO_SSH_KEY
follows the repository's established deployment configuration pattern, matching the implementation in other working workflows including beta releases and PR deployments.🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Searching references to PR_REPO and PR_REPO_SSH_KEY in the codebase. rg 'PR_REPO|PR_REPO_SSH_KEY'Length of output: 30
Script:
#!/bin/bash # Search specifically in workflow files with case-insensitive pattern fd -e yml -e yaml . .github/workflows/ --exec rg -i 'repo|ssh_key|deploy' # List all workflow files to ensure we don't miss any fd -e yml -e yaml . .github/workflows/Length of output: 6899
.github/workflows/build-frontend.yml (3)
10-10
: Good practice to make frontend_name required.
Markingfrontend_name
as required helps avoid misconfigurations when running the workflow.
76-77
: Check for accidental leakage.
Storingrepo_name
andrepo_deploy_secret_name
in plain text is typically safe since they’re not actual credentials, but carefully confirm that no sensitive information is inadvertently included.
87-88
: Be mindful of artifact contents.
Archivingrepo_name
andrepo_deploy_secret_name
might be necessary for downstream steps, but double-check that nothing sensitive is included in case you share or retain these artifacts long-term..github/workflows/deploy-frontend.yml (3)
13-13
: Trigger inclusion for "New ZO Release" looks correct.
Having this new workflow trigger ensures the newly introduced ZO release flow integrates with existing deployment steps.
33-34
: Outputs look good; watch for misconfigurations.
Exposingrepo_name
andrepo_deploy_secret_name
as outputs is reasonable. Just confirm these values are valid in the artifact.
39-40
: Verify external repository and secret references.
Pullingrepo_name
from the artifact and usingssh-key: ${{ secrets[steps.vars.outputs.repo_deploy_secret_name] }}
can fail if the secret does not exist. Ensure that appropriate secrets are set in the repository’s settings.✅ Verification successful
Repository and secret references are properly configured ✅
The workflow uses repository variables (
vars.PR_REPO
) and secrets (PR_REPO_SSH_KEY
) correctly. If the secret is missing, the workflow will fail fast with a clear error message, preventing any incomplete deployments. This is a secure setup following GitHub Actions best practices for GitHub Pages deployments.🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Listing available repository secrets to confirm that outputs.repo_deploy_secret_name is defined. gh secret listLength of output: 172
Script:
#!/bin/bash # Check the full workflow file to understand variable setup cat .github/workflows/deploy-frontend.yml # Look for any related configuration files fd -t f -e yml -e yaml . .github/Length of output: 4505
Script:
#!/bin/bash # Check one of the build workflows that creates the artifacts cat .github/workflows/build-go-wr-pr.yml # Also check the main build workflow cat .github/workflows/build-frontend.ymlLength of output: 4169
Script:
#!/bin/bash # Check release workflows that might show how these parameters are configured cat .github/workflows/beta-go-release.yml cat .github/workflows/new-release.ymlLength of output: 2244
Describe your changes
Issue or discord link
Testing/validation
Checklist before requesting a review (leave this PR as draft if any part of this list is not done.)
yarn run mini-ci
locally to validate format and lint.Summary by CodeRabbit