Add PR preview workflow (GitHub Actions + ArgoCD) - #2194
Open
satyamz wants to merge 1 commit into
Open
Conversation
Replaces the Jenkins preview pipeline (stellar/pipelines) with the gate -> build -> publish flow from stellar/actions/sdf-pr-preview. ArgoCD ApplicationSets in stellar/kube deploy a preview per PR carrying the 'preview' label and tear it down on close. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Comment on lines
+43
to
+49
| - uses: actions/checkout@v6 | ||
| if: steps.gate.outputs.member == 'true' | ||
| with: | ||
| ref: ${{ github.event.pull_request.head.sha }} | ||
| persist-credentials: false | ||
|
|
||
| - id: ecr-login |
Contributor
There was a problem hiding this comment.
Pull request overview
Adds automated per-PR preview deployments using GitHub Actions, ECR, and ArgoCD.
Changes:
- Gates preview builds to trusted organization members.
- Builds and publishes PR-specific Docker images.
- Manages preview labels and URL comments.
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+43
to
+47
| - uses: actions/checkout@v6 | ||
| if: steps.gate.outputs.member == 'true' | ||
| with: | ||
| ref: ${{ github.event.pull_request.head.sha }} | ||
| persist-credentials: false |
|
Preview is available here: |
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.
Migrates this repo's per-PR preview environments from the Jenkins preview pipeline (stellar/pipelines) to GitHub Actions + ArgoCD.
How it works
previewlabel, checks org membership) -> build & push the preview image(s) to dev ECR -> publish (verifies the images exist, restores the label, comments the preview URL).preview-laboratoryin stellar/kube watch PRs carrying thepreviewlabel and deploy onecharts/pr-previewsrelease per PR. Closing the PR tears the preview down.pr-<number>-<head-sha>:dev/laboratoryPreview URL(s)
https://laboratory-pr-<number>.previews.kube001.services.stellar-ops.comSecurity
The workflow runs on
pull_request_target(required for fork PRs to get OIDC + label/comment permissions). Per the sdf-pr-preview caller contract: the gate runs before any PR code is checked out, and every later step is guarded bysteps.gate.outputs.member == 'true', so non-member PRs never build.Before merging
previewlabel exists in this repoPREVIEW_BOT_APP_IDrepo variable andPREVIEW_BOT_PRIVATE_KEYsecret are set🤖 Generated with Claude Code