STAC-25463 Add GitHub Actions check-test workflow (integrations CI migration phase 1) - #362
Open
LouisParkin wants to merge 3 commits into
Open
STAC-25463 Add GitHub Actions check-test workflow (integrations CI migration phase 1)#362LouisParkin wants to merge 3 commits into
LouisParkin wants to merge 3 commits into
Conversation
…gration phase 1)
Ports the pure-Python half of .gitlab-ci.yml to GitHub Actions as the first
phase of moving stackstate-agent-integrations off GitLab (STAC-25142).
What moved:
* The `test_<check>` job family -> a single `check-tests` matrix.
* The per-job `changes:` rules -> .github/scripts/select-checks.sh, which
reproduces them with `git diff` against the merge base. Done in plain git
because StackVista enforces a strict third-party action allowlist.
* The `checksdev validate *` commands that rode inside
test_stackstate_checks_base -> their own job, so a metadata failure reads
as its own PR check.
Scoped out, with reasons recorded in the workflow header:
* The five Docker-dependent suites (splunk x4 + stackstate_checks_dev) are
phase 2; both public ARC runners ship a DinD sidecar, so this is about
exercising that path, not provisioning it.
* test_postgres is dead config - it tests a `postgres` check that does not
exist in this repository.
* print_env is not ported at any phase: a bare `printenv` on a PUBLIC repo
publishes every CI credential in scope to a world-readable log.
* There is no Windows lane to port. `.gitlab-ci.yml` defines a `.windows_env`
anchor that no job has ever referenced, and Windows is not a supported
target.
* Publishing stays on GitLab until integrations gets its own publishing role
(pulumi-infra section 7.4), so the GitLab pipeline remains live.
Phase 1 needs no new secret provisioning: REGISTRY_HOST/USER/PASSWORD are
org-level visibility=all (STAC-25350) and so already reach this PUBLIC repo.
The image reference composes vars.REGISTRY_HOST + /docker rather than using
vars.REGISTRY_DOCKER_URL, which is private-visibility and unreadable here.
Validated: actionlint clean (with a new .github/actionlint.yaml declaring the
self-hosted labels), zizmor clean, shellcheck clean, and the selector exercised
against real git history for the push, single-check, multi-check, shared-library
and no-match cases.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…plied pulumi-infra #262 is merged and applied (~ 1 updated), so docker-public can now pick up jobs from this repository. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The GitLab `.linux_test` anchor ran .setup-scripts/setup_artifact_registry.sh immediately before `checksdev test`, and the port dropped it. Fourteen of the fifteen phase-1 suites resolve everything from public PyPI and did not notice, but the vsphere suite pins vsphere-automation-sdk==1.82.0, which public PyPI does not carry (only a 0.0.1 placeholder), so it failed with: ERROR: Could not find a version that satisfies the requirement vsphere-automation-sdk==1.82.0 (from versions: 0.0.1) Restores the step in the same position as GitLab had it. The script writes ~/.pip/pip.conf and a 0600 ~/.netrc, so credentials never appear in the index URL. The step is guarded on the credentials being present rather than run unconditionally: only one suite actually needs the private index, so an absent credential should not fail the fourteen that do not. When it is missing the job emits a warning annotation naming the consequence, and the affected suite still fails visibly on its own unresolvable pin. Requires the pull-only grant in StackVista/pulumi-infra#263. setup_artifactory_docker.sh stays out; it is a registry docker login that only the deferred Docker suites need, and it comes across with them in phase 2. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.
Jira: https://stackstate.atlassian.net/browse/STAC-25463 (parent: STAC-25142)
First phase of moving
stackstate-agent-integrationsCI off GitLab. Purely additive —.gitlab-ci.ymlis untouched and keeps running, so this can land without a cutover.What moved
test_<check>job family (20 near-identical jobs)check-testsmatrixchanges:rules.github/scripts/select-checks.sh(plaingit diffvs merge base)checksdev validate *riding insidetest_stackstate_checks_basevalidatejobservices: docker:24-dind+DOCKER_HOST: tcp://docker:2375Path filtering is done in
gitrather than a path-filter action because StackVista enforces a strict third-party action allowlist, andgit diffagainst the merge base is precisely what the GitLab rule meant.Scoped out (each reasoned in the workflow header)
splunk_{base,health,metric,topology}+stackstate_checks_dev. These are the only suites needing a Docker daemon. Phase 2; the runners already provide DinD, so it is about exercising that path, not provisioning it.test_postgres— dead config. It tests apostgrescheck that does not exist in this repository. Dropped, not pending.print_env— not ported at any phase. It is a bareprintenv, and this repo is public, so it publishes every CI credential in scope to a world-readable log. Same hazard class as thesign_debian_package.shfinding on the agent..gitlab-ci.ymldefines a.windows_envanchor that no job has ever referenced, and Windows is not a supported target. The orphanedconda_env.ps1/windows_*.cmdhelpers can retire with the GitLab pipeline (STAC-25464).dockerjob stay on GitLab until integrations gets its own publishing role (pulumi-infra section 7.4).CERBERUS_LAMBDA_URLis a private-visibility org secret unreadable from a public repo. Follow-up.Credentials
Phase 1 needs no new secret provisioning:
REGISTRY_HOST/REGISTRY_USER/REGISTRY_PASSWORDare org-levelvisibility: all(STAC-25350) and already reach this public repo. Note the image ref composesvars.REGISTRY_HOST+/dockerrather than usingvars.REGISTRY_DOCKER_URL, which is private-visibility and not readable here.Validation
actionlintclean — added.github/actionlint.yamldeclaring the self-hosted*-publiclabelszizmorclean (2 suppressed = the documentedunpinned-imagesignores on the container ref)shellcheckcleanSelector exercised against real git history:
push/ dispatchzabbix/["zabbix"]kubelet/+vsphere/["kubelet","vsphere"][](matrix skips)This PR self-validates — the workflow runs against this very PR, so the image path and runner labels are proven before merge.