Skip to content

Use GitHub, GitHub Actions and GHCR instead of the Gitea stand-in; Argo CD pulls the deployment #85

Open
0 of 2 issues completed

Description

@ephico2real2

Part of #28

Related: #13, #14, #63 and #64

Why

The owner's direction, 2026-11-05: the project is on GitHub, so its Git host and pipeline are GitHub. Gitea should not be in the deployment path.

What is wrong. deploy/helm/cmapi-git, core/git/gitea.py and deploy/environments/crc.yaml use a Gitea stand-in. docs/01 line 140 names GitHub REST as the default GitProvider, and Gitea is not in the design. As a result the GitHub adapter has never been exercised (#61), the worker posts its own required checks (#60), and the bot uses basic auth over plain HTTP (#59).

Target

  • cluster-configs-nonprod is a GitHub repository. The worker opens PRs there, and that repository's own Actions run the kubeconform and Kyverno checks that branch protection requires.
  • Actions in cmapi build images and push them to GHCR by digest, with provenance attestation.
  • Argo CD on the cluster pulls: the namespaces from cluster-configs, and cmapi's own deployment from its manifests. Nothing reaches into the Mac, so no self-hosted runner. GitHub's guidance: self-hosted runners "should almost never be used for public repositories" (https://docs.github.com/en/actions/reference/security/secure-use), and cmapi is public.
  • A kind end-to-end job in Actions in the shape of cilium-implementation-poc's demo55-ci.yaml and lab-*.yaml, with demo57-ci.yaml's conventions: one step per check, if: !cancelled(), actions pinned by commit, persist-credentials: false, least permissions, and a guard that every test is named by the workflow.

To settle in the two designs, with measurements

  1. How a new digest reaches Argo CD. Argo CD does not watch registries. Candidates: Actions records the digest in Git, or Argo CD Image Updater. Weigh the design's rule that every change has a diff, branch protection on the target branch, and the footprint on a node at 79% of memory requests.
  2. How the worker authenticates to GitHub. docs/01 line 785 says "GitHub App or deploy key"; a deploy key cannot post statuses or open PRs. core/git/base.py takes one static token today, and a GitHub App needs installation-token exchange.
  3. Whether pods on CRC reach github.com, api.github.com and ghcr.io. The earlier probe of raw.githubusercontent.com printed nothing, so this is unverified.

The handover records the later decisions. Actions pushes the image, tests that digest and commits it to branch deployed/crc. Argo CD follows that branch. The owner creates the GitHub App and makes each GHCR package public.

What kind cannot prove

user.openshift.io Users and Groups, Routes and SCCs exist only on OpenShift. core/clients/kube.py whoami() already falls back to SelfSubjectReview, and the design has cmapi read Users, Identities, Groups and GroupSyncs. CRC stays the gate for those, and CI must say what it did not prove. Hosted runners have no nested virtualisation (demo55-ci.yaml, citing actions/runner-images#7541), so CRC itself cannot run there.

Acceptance criteria

  • A request through the portal or API on CRC opens a real PR on GitHub, Actions' checks turn green, the bot merges, and Argo CD creates the namespace, shown by a new proof script in deploy/, not written yet
  • A merge to main of cmapi reaches CRC with no command on the Mac, at the digest CI built, verified against /version and its attestation, shown by a new CI job in .github/workflows/, not written yet
  • Gitea's chart and adapter are removed, shown by a new test in cmapi/tests/service/, not written yet

Tasks

Definition of done

  • Mockup approved, or the work has no screen and no API shape
  • Draft pull request open
  • Build: tests fail before the change and pass after it
  • Review ruled
  • Merged with its proof
  • Released on the default branch

Class

INV and TDT. Actions, GHCR, the attestation and the end-to-end CI job are new. The task also removes the Gitea stand-in, an earlier shortcut.

Source

How to prove it is done. A request through the portal or API on CRC opens a real PR on GitHub, Actions' checks turn green, the bot merges, and Argo CD creates the namespace. A merge to main of cmapi reaches CRC with no command on the Mac, at the digest CI built, verified against /version and its attestation. Then remove Gitea's chart and adapter, closing #59 and #60, and #61 when exercised.

The issue said when filed: Part of #13, #14, #63 and #64.

Sub-issues

Sub-issues

0 of 2 Issues completed
Loading 2 sub-issues

Activity

  1. added a commit that references this issue on Nov 5, 2026
  2. added
    In-Progress
    class:INV
    class:TDT
    on Nov 13, 2026
  3. added
    status:partly-fixed
    task
    on Nov 13, 2026
  4. ephico2real2 commented on Nov 13, 2026

    @ephico2real2
    OwnerAuthor

    Work tag: In-Progress. PR #89 says Part of #85. Its merge commit 9fd230a holds a part: the plain YAML deployment (#88). The GitHub adapter, the release to GHCR and Argo CD are not done. Read from gh and git at 2026-11-13T09:18Z.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    In-Progressclass:INVclass:TDTstatus:partly-fixedtask

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions