TT-16030: run the jira-linter from the published image - #162
kofoworola merged 5 commits into
Conversation
Replaces the two build steps with a single `docker run`, so the action no longer installs a Go toolchain and compiles the linter on every pull request run in every repository that uses it. The image lives in a private ECR registry, which rules out a Docker container action: `using: docker` gives the runner no way to supply registry credentials for its own image pull. The action therefore stays composite, and gains two steps that assume ecr_rw_tyk and log in to ECR before the container runs. Everything after the linter step is unchanged. Branch resolution, the stderr capture, the failure comment body, the two sticky comment steps, and the final exit all stay exactly as they were. Each variable is passed to `docker run` by name rather than by value, so no secret reaches the command line or the workflow log. jira-lint.yaml now declares id-token: write, and the doc page records that callers have to grant it too, since a called workflow cannot hold permissions its caller did not grant. Depends on the image published by the parent branch.
|
This pull request transitions the Files Changed Analysis
Architecture & Impact Assessment
Execution Flow ComparisonBefore (Build from Source): graph TD
A[Start Workflow] --> B[Set up Go Toolchain];
B --> C[Build Linter from Source];
C --> D[Run Linter Binary];
D --> E[End];
After (Run from Image): graph TD
A[Start Workflow] --> B[Assume AWS Role via OIDC];
B --> C[Login to ECR];
C --> D[Pull & Run Linter Docker Image];
D --> E[End];
Scope Discovery & Context Expansion
Metadata
Powered by Visor from Probelabs Last updated: 2026-09-16T12:42:55.747Z | Triggered by: pr_updated | Commit: f355dcb 💡 TIP: You can chat with Visor using |
zizmor findings
Full details are in the workflow run. |
Security Issues (3)
Architecture Issues (2)
Performance Issues (1)
Quality Issues (2)
Powered by Visor from Probelabs Last updated: 2026-09-16T12:42:29.449Z | Triggered by: pr_updated | Commit: f355dcb 💡 TIP: You can chat with Visor using |
Nothing in CI exercised jira-linter/action.yaml. test-jira-linter runs the Go unit tests, and the publish workflow only builds the image, so a change to the action itself reached consumers unverified. This mirrors how tyk calls the action, in .github/workflows/jira-pr-validator.yaml, with one difference: it uses the local `./jira-linter` path rather than @production, so a pull request validates its own version of the action. The job declares id-token: write, which the action now needs to assume ecr_rw_tyk and pull the image from ECR. Requires JIRA_BASE_URL and JIRA_READ_AUTH to exist as repository or organization secrets here, not only to be passed in by callers.
392f2a2 to
8df5229
Compare
Restores jira-linter/action.yaml to the version on main, which installs a Go toolchain and runs `go install ./cmd/linter` on every run. This exists only to measure the two approaches side by side. The jira-lint-self.yml check now exercises the setup-go path, and is renamed to "lint without container" so the two runs are distinguishable in the checks list. Revert this commit to restore the container approach. It touches only jira-linter/action.yaml and the job name, so `git revert` is clean.
8df5229 to
1dfd7ec
Compare
Restores the container approach in jira-linter/action.yaml. The timing comparison is done, so the action goes back to pulling the prebuilt image from ECR rather than installing a Go toolchain and compiling on every run. The self-check job is renamed to "lint with container", pairing with the "lint without container" name the comparison used. The ci-test.yml bump to Go 1.26 is kept rather than reverted. It is unrelated to the comparison and is required, because go.mod declares go 1.26 and setup-go sets GOTOOLCHAIN=local.
The workflow existed to validate jira-linter/action.yaml on this repository's own pull requests, and to compare the container and setup-go approaches. Both runs are done: the container path was confirmed working against the real Jira API, and the setup-go path was confirmed broken by the Go version mismatch. Removing it leaves action.yaml unexercised by CI here again.
7d6fe6a
into
feat/TT-16030/jira-linter-docker
PR #162 carried this change but merged into its stacked base branch rather than main, so main never received it. main currently holds go.mod requiring go 1.26 from #155, alongside an action.yaml that pins setup-go to 1.24.7. setup-go sets GOTOOLCHAIN=local, so `go install` fails with: go: go.mod requires go >= 1.26 (running go 1.24.7; GOTOOLCHAIN=local) Every repository on @production is failing its Jira check as a result. This replaces the two build steps with a single `docker run` against the image published to ECR, so the action stops installing a Go toolchain and compiling on every run. The image lives in a private registry, which rules out a Docker container action, so the action stays composite and gains two steps that assume ecr_rw_tyk and log in to ECR. Everything after the linter step is unchanged: branch resolution, the stderr capture, the failure comment body, both sticky comment steps, and the final exit. ci-test.yml moves to Go 1.26 to match go.mod. Variables reach the container by name rather than by value, so no secret appears in the command line or the run log.
What this does
TT-16030
Stops the action installing a Go toolchain and compiling the linter on every pull request run. It runs the published image instead.
Set up GoandBuild Jira Linterare replaced by onedocker run. Everything after the linter step is untouched.Ticket Details
TT-16030
Generated at: 2026-09-16 12:39:23
Before VS After