V1Alpha2 Examples
This directory contains example configurations for the v1alpha2 controller-based architecture.
Overview
The v1alpha2 architecture introduces a modular, provider-based system where platform components are managed through separate Custom Resources:
- Platform: Orchestrates the overall IDP platform by referencing provider CRs
- GiteaProvider: Manages Gitea Git server installation and configuration
- NginxGateway: Manages Nginx Ingress Controller installation and configuration
- ArgoCDProvider: Manages ArgoCD GitOps deployment tool installation and configuration
Quick Start
1. Create Provider CRs
First, create the individual provider CRs:
# Create Gitea provider
kubectl apply -f giteaprovider.yaml
# Create Nginx gateway provider
kubectl apply -f nginxgateway.yaml
# Create ArgoCD GitOps provider
kubectl apply -f argocdprovider.yaml
2. Create Platform CR
Then create the Platform CR that references these providers:
kubectl apply -f platform-with-gateway.yaml
3. Check Status
Monitor the installation progress:
# Check Platform status
kubectl get platform -n default
# Check individual provider statuses
kubectl get giteaprovider -n gitea
kubectl get nginxgateway -n ingress-nginx
kubectl get argocdprovider -n argocd
# View detailed status
kubectl describe platform my-platform -n default
Architecture
The Platform CR aggregates status from all referenced providers using duck-typing:
Platform CR (my-platform)
├── Git Providers
│ └── my-gitea (GiteaProvider)
├── Gateways
│ └── my-nginx (NginxGateway)
└── GitOps Providers
└── my-argocd (ArgoCDProvider)
Each provider controller:
- Installs its respective component (Gitea, Nginx, etc.)
- Waits for the component to be ready
- Updates its status with duck-typed fields
- Sets the Ready condition when operational
The Platform controller:
- Monitors all referenced providers
- Aggregates their readiness status
- Updates Platform status to Ready when all providers are ready
Duck-Typed Status Fields
Git Providers (e.g., GiteaProvider)
endpoint: External URL for web UI and cloninginternalEndpoint: Cluster-internal URL for API accesscredentialsSecretRef: Secret containing access credentials
Gateway Providers (e.g., NginxGateway)
ingressClassName: Name of the ingress class to useloadBalancerEndpoint: External endpoint for accessing servicesinternalEndpoint: Cluster-internal API endpoint
GitOps Providers (e.g., ArgoCDProvider)
endpoint: External URL for ArgoCD web UIinternalEndpoint: Cluster-internal URL for API accesscredentialsSecretRef: Secret containing admin credentials
All providers expose a Ready condition in their status.
Files
- giteaprovider.yaml: Example GiteaProvider configuration
- nginxgateway.yaml: Example NginxGateway configuration
- argocdprovider.yaml: Example ArgoCDProvider configuration
- platform-with-gateway.yaml: Example Platform CR referencing git and gateway providers
- platform-complete.yaml: Complete Platform CR example with all provider types (git, gateway, and gitops)
Migration from V1Alpha1
The v1alpha2 architecture is designed to coexist with v1alpha1. The existing Localbuild CR continues to work, but the new provider-based architecture offers:
- Better separation of concerns
- Easier customization of individual components
- Support for alternative providers (e.g., GitHub, GitLab, Envoy)
- Improved observability through kubectl
- GitOps-friendly declarative management
Next Steps
After the platform is ready, you can:
- Access Gitea: Check the
endpointfield in GiteaProvider status - Access ArgoCD: Check the
endpointfield in ArgoCDProvider status - Deploy applications using ArgoCD and the Nginx Ingress
- Add more providers to the Platform CR as they become available