feat!: migrate to argocd-operator on k3s; drop OpenShift-isms (Phase A)#5
Merged
feat!: migrate to argocd-operator on k3s; drop OpenShift-isms (Phase A)#5
Conversation
Pre-commit testing runs on a self-hosted ARC runner that depends on the in-cluster actions-runner-controller, which is offline during the libvirt-host migration. Move the test job to GitHub-hosted ubuntu- latest so PRs validate; revert when the new k3s cluster has ARC runners up. The sync job stays on `arc` because it needs in-cluster API access via its SA token. It will not run until ARC dind runners are up.
Re-targets kustomize-cluster from OpenShift Local (CRC) onto vanilla
k3s, consumed by argocd-operator (community, upstream of OpenShift
GitOps — same argoproj.io/v1beta1 ArgoCD CRD).
Renames:
- namespace openshift-gitops -> argocd (~22 files)
- ArgoCD CR name openshift-gitops -> argocd
- SA openshift-gitops-argocd-application-controller ->
argocd-argocd-application-controller (wait-for-* jobs)
- workloads/openshift-gitops/ -> workloads/argocd/
- argocd-server.openshift-gitops.svc.cluster.local ->
argocd-server.argocd.svc.cluster.local (argocd-proxy)
- TunnelBinding subject openshift-gitops-server -> argocd-server
- PostSync hooks oc -> kubectl, image-registry.openshift-image-
registry.svc:5000/openshift/cli:latest -> bitnami/kubectl:latest
- ci-token-sync image-registry.../public-registry/gh-cli:latest ->
ghcr.io/makeitworkcloud/gh-cli:latest
Deletions (OpenShift-only constructs that don't apply to k3s):
- bootstrap/console-branding/ — OpenShift web console branding
- bootstrap/secrets/openshift-oauth/ — OpenShift OAuth provider
config; ArgoCD's own Dex GitHub SSO (in argocd-config.yaml)
remains the SSO path
- bootstrap/public-registry.yaml — OpenShift internal-registry-
backed namespace; image refs swapped to ghcr.io
- operators/cert-manager/{ingress-patch,openshift-ingress-config}
.yaml — patched OpenShift's IngressController + componentRoutes
- operators/cert-manager/wildcard-certificate.yaml — the wildcard
LE cert was a CRC ingress workaround; with public traffic
flowing through Cloudflare Tunnels (already in this repo via
cloudflare-operator + TunnelBinding), TLS is terminated at the
Cloudflare edge and an in-cluster wildcard cert is dead code.
- workloads/arc/imagestream.yaml — image.openshift.io ImageStream
CI sync job rewritten to kubectl + the new bootstrap Application
names (bootstrap-secrets / gitops-operators / gitops-workloads).
The ArgoCD CR's repo: block (KSOPS install initContainer, custom-
tools volume, sops-age-keys volume, env vars) is unchanged — same
CRD shape, same KSOPS pattern. The sops-age-keys Secret is created
in the argocd namespace by tfroot-libvirt's k3s cloud-init pre-
bootstrap.
BREAKING CHANGE: Cluster bootstrap now requires argocd-operator
(community) installed before this kustomization is applied. Done
automatically by tfroot-libvirt's k3s cloud-init runcmd. Operators
synced via OLM Subscriptions (cert-manager, awx, grafana) will
fail to reconcile on k3s and need replacing with upstream Helm
charts/manifests in a follow-up phase.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.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.
Summary
Phase A of the k3s migration: re-targets
kustomize-clusterfrom OpenShift Local (CRC) onto vanilla k3s, consumed byargocd-operator(community, upstream of OpenShift GitOps — sameargoproj.io/v1beta1 ArgoCDCRD, so the existingrepo:block with KSOPS/Dex/RBAC works unchanged).This is the minimum set of changes for ArgoCD to bootstrap successfully on k3s. Phase B (replace OLM Subscriptions for cert-manager/awx/grafana with upstream Helm) and Phase C (clean up
openshift-monitoringPrometheus scrape refs,system:openshift:sccreferences in workloads) follow as separate PRs.Bundles the previously-staged repo-local opencode config (the prior commit on this branch).
Renames
openshift-gitops→argocd(~22 files)name: openshift-gitops→name: argocdopenshift-gitops-argocd-application-controller→argocd-argocd-application-controllerworkloads/openshift-gitops/→workloads/argocd/argocd-server.openshift-gitops.svc.cluster.local→argocd-server.argocd.svc.cluster.localopenshift-gitops-server→argocd-serveroc→kubectl, OpenShift CLI ImageStream →bitnami/kubectl:latestimage-registry.openshift-image-registry.svc:5000/public-registry/gh-cli→ghcr.io/makeitworkcloud/gh-cliDeletions (OpenShift-only constructs)
bootstrap/console-branding/— OpenShift web console brandingbootstrap/secrets/openshift-oauth/— cluster-wide OpenShift OAuth provider config; ArgoCD's own Dex GitHub SSO remains the SSO pathbootstrap/public-registry.yaml— OpenShift internal-registry-backed namespaceoperators/cert-manager/{ingress-patch,openshift-ingress-config}.yaml— patched OpenShift's IngressController + componentRoutesoperators/cert-manager/wildcard-certificate.yaml— the wildcard*.apps.makeitwork.cloudLE cert was a CRC ingress workaround. With public traffic flowing through Cloudflare Tunnels (already in this repo viacloudflare-operator+TunnelBinding), TLS terminates at Cloudflare's edge and an in-cluster wildcard cert is dead code.workloads/arc/imagestream.yaml— OpenShift ImageStreamBootstrap chain
The argocd-operator install + sops-age-keys Secret + bootstrap apply is in the companion tfroot-libvirt PR #2. The
sops_age_keyvalue needs to be added totfroot-libvirt/secrets/secrets.yaml(sops-encrypted; same age recipient as the rest).Test plan
kustomize build bootstrap/passes locallykustomize build workloads/apps/passes locallyPre-commit Testsjob passes (nowubuntu-latest)openshift-monitoring(Phase C)Migration notes for operators
operator.yamlSubscription resources land in etcd but go nowhere. Expected; see Phase B.wildcard-apps-makeitwork-cloud-tlsSecret (none currently in repo) will need re-plumbing through Cloudflare.