Zum Hauptinhalt springen
Echtzeit-Radar & Feeds
Alle RSS Feeds ➔
👥 Community & Social
Windows Tipps & SecurityGrafikkarte vor Überhitzung schützen: So geht’s(25.09.2026 um 08:00 Uhr)
••••••••••
Windows Tipps & SecurityGrafikkarte vor Überhitzung schützen: So geht’s(25.09.2026 um 08:00 Uhr)
••••••••••
Intelligence View
⚡ tsecurity.de Intelligence

🚀 Building a GitOps Infrastructure Pipeline with Crossplane and Argo CD

From manual kubectl commands to fully automated infrastructure management - here's how I built a production-ready GitOps pipeline TL;DR I built a complete GitOps infrastructure management system using: 🎯 Argo CD for GitOps …

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!

From manual kubectl commands to fully automated infrastructure management - here's how I built a production-ready GitOps pipeline









TL;DR



I built a complete GitOps infrastructure management system using:




  • 🎯 Argo CD for GitOps automation

  • ⚡ Crossplane for infrastructure provisioning

  • 🔄 App-of-Apps pattern for scalable application management

  • 📦 MetalLB as the infrastructure example

  • 🎭 Sync waves for dependency management



Result: Infrastructure changes now happen through Git commits, with full automation and zero manual intervention.









The Problem I Solved



Managing Kubernetes infrastructure traditionally sucks:




# The old way - manual and error-prone
kubectl apply -f metallb-config.yaml
kubectl apply -f ingress-controller.yaml
kubectl apply -f monitoring-stack.yaml
# Oh no! Order matters... 💥
# Which version is running in production? 🤷‍♂️
# Who made that change? 🕵️‍♂️






I wanted infrastructure that:




  • ✅ Lives in Git (version controlled)

  • ✅ Deploys automatically (no manual steps)

  • ✅ Handles dependencies (no ordering issues)

  • ✅ Self-heals (drift detection & correction)

  • ✅ Provides audit trails (who, what, when)









The Solution Architecture






graph LR
A[Git Commit] --> B[Argo CD]
B --> C[Crossplane]
C --> D[Kubernetes Resources]
B --> E[Sync Waves]
E --> F[Ordered Deployment]









🎯 Step 1: App-of-Apps Pattern



Instead of managing 50+ individual Argo CD applications, I use the App-of-Apps pattern:




# One app to rule them all
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: homelab-root
annotations:
argocd.argoproj.io/sync-wave: "-1"
spec:
source:
repoURL: https://github.com/jamilshaikh07/homelab-gitops.git
path: apps # 👈 All child apps live here
syncPolicy:
automated:
prune: true # 🗑️ Clean up deleted resources
selfHeal: true # 🔧 Fix manual changes






Benefits:




  • One root app manages everything

  • New apps = just add YAML files

  • Automatic discovery and deployment









⚡ Step 2: Crossplane for Infrastructure



Crossplane lets me manage infrastructure through Kubernetes APIs. Here's the magic:




# Instead of direct kubectl apply...
apiVersion: kubernetes.crossplane.io/v1alpha1
kind: Object
metadata:
name: metallb-ipaddresspool
annotations:
argocd.argoproj.io/sync-wave: "2" # 👈 Depends on provider
spec:
providerConfigRef:
name: in-cluster
forProvider:
manifest:
apiVersion: metallb.io/v1beta1
kind: IPAddressPool
metadata:
name: homelab-pool
namespace: metallb-system
spec:
addresses:
- 10.20.0.81-10.20.0.99 # 🎯 My LoadBalancer IP range






Why Crossplane Objects?




  • 🔄 Continuous reconciliation (drift detection)

  • 📊 Rich status reporting (health, errors)

  • 🎭 Dependency management (waits for providers)

  • 🔒 RBAC integration (secure access)









🎭 Step 3: Sync Waves for Dependencies



Order matters in infrastructure! I use sync waves to ensure proper sequencing:




# Wave -1: Root app-of-apps
argocd.argoproj.io/sync-wave: "-1"

# Wave 0: Install Crossplane providers
argocd.argoproj.io/sync-wave: "0"

# Wave 1: Provider configs + RBAC
argocd.argoproj.io/sync-wave: "1"

# Wave 2: Infrastructure resources
argocd.argoproj.io/sync-wave: "2"






Result: No more "CRD not found" or "provider not ready" errors! 🎉









🔐 Step 4: RBAC - The Critical Missing Piece



Crossplane needs permissions to manage your infrastructure. This is often overlooked:




apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: crossplane-provider-kubernetes-metallb
rules:
- apiGroups: ["metallb.io"]
resources: ["ipaddresspools", "l2advertisements"]
verbs: ["*"]
---
# Bind to the provider's service account
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: crossplane-provider-kubernetes-metallb
roleRef:
kind: ClusterRole
name: crossplane-provider-kubernetes-metallb
subjects:
- kind: ServiceAccount
name: provider-kubernetes-xxxxx # 👈 Get from kubectl
namespace: crossplane-system






Pro tip: Restart provider pods after RBAC changes!









🧪 Testing the Complete Pipeline



Time for the moment of truth:




# 1. Bootstrap (one-time manual step)
kubectl apply -f argocd/app-of-apps.yaml

# 2. Check GitOps automation
kubectl -n argocd get applications
NAME SYNC STATUS HEALTH STATUS
crossplane-provider-kubernetes Synced Healthy ✅
homelab-root Synced Healthy ✅
metallb-config Synced Healthy ✅

# 3. Verify infrastructure was created
kubectl -n metallb-system get ipaddresspools.metallb.io
NAME ADDRESSES
homelab-pool ["10.20.0.81-10.20.0.99"] ✅

# 4. Test LoadBalancer functionality
kubectl create deployment nginx --image=nginx
kubectl expose deployment nginx --type=LoadBalancer --port=80

kubectl get svc nginx
NAME TYPE EXTERNAL-IP PORT(S)
nginx LoadBalancer 10.20.0.82 80:30114/TCP ✅

# 5. Verify connectivity
curl http://10.20.0.82
<!DOCTYPE html>
<html>
<head><title>Welcome to nginx!</title></head>
# 🎉 SUCCESS!






It works! Infrastructure deployed entirely through GitOps! 🚀









📁 Repository Structure






homelab-gitops/
├── argocd/
│ └── app-of-apps.yaml # 🏠 Root application
├── apps/
│ ├── crossplane-provider-kubernetes-app.yaml
│ └── metallb-config-app.yaml # 👶 Child applications
├── crossplane/
│ └── provider-kubernetes/
│ ├── provider.yaml # ⚡ Crossplane provider
│ ├── providerconfig.yaml # ⚙️ Configuration
│ └── rbac.yaml # 🔐 Permissions
└── metallb/
├── metallb-ipaddresspool.yaml # 🌐 Infrastructure
└── metallb-l2advertisement.yaml # 📦 Resources












💡 Key Lessons Learned






1. API Versions Are Critical



Different provider versions use different APIs:




# v0.13.0 uses v1alpha1
apiVersion: kubernetes.crossplane.io/v1alpha1

# Newer versions use v1alpha2
apiVersion: kubernetes.crossplane.io/v1alpha2









2. Bootstrap is Still Manual



Even with full GitOps, you need one manual step:




kubectl apply -f argocd/app-of-apps.yaml






After this, everything else is automated!






3. RBAC Debugging



If Crossplane objects stay "NotReady":




# Check provider permissions
kubectl -n crossplane-system describe object metallb-ipaddresspool

# Common fix: restart provider after RBAC changes
kubectl -n crossplane-system delete pod -l pkg.crossplane.io/provider=provider-kubernetes









4. YAML Formatting Matters



Watch your indentation! This kept my root app OutOfSync:




# ❌ Wrong
destination:
server: https://kubernetes.default.svc
namespace: crossplane-system

# ✅ Correct
destination:
server: https://kubernetes.default.svc
namespace: crossplane-system












🚀 What's Next?



This foundation scales to manage ANY infrastructure:




# Database clusters
kind: PostgreSQLCluster

# Service meshes
kind: Istio

# Monitoring stacks
kind: PrometheusStack

# Certificate management
kind: ClusterIssuer

# Storage solutions
kind: StorageClass






The pattern stays the same:




  1. Define in YAML

  2. Commit to Git

  3. Argo CD syncs automatically

  4. Crossplane provisions infrastructure

  5. Profit! 💰









🎉 Results



Before:




  • Manual kubectl commands

  • Configuration drift

  • No audit trail

  • Deployment anxiety 😰



After:




  • Infrastructure as Code

  • Git-driven deployments

  • Automatic drift correction

  • Pull request reviews

  • Confidence in production 😎



Infrastructure changes are now as simple as creating a pull request!









🔗 Resources








What infrastructure will you GitOps next? Drop a comment and let me know what you're planning to automate! 👇






Follow me for more cloud-native and DevOps content! 🚀

1. Sofort-Triage & Abwehrmaßnahmen

SOC Incident Playbook: Remote Code Execution (RCE) Defense
Syntax validiert (0 Fehler)
title: Detect Exploitation - 🚀 Building a GitOps Infrastructure Pipeline with Crossplane and Argo CD
id: 0b2ee8c6-f991-4007-a755-dd0982e66419
status: experimental
description: Automatisch generierte SIEM-Erkennungsregel basierend auf CTI Intelligence
references:
  - https://tsecurity.de/
author: iShareStuff CTI Automated Detection Engine
date: 2026-09-25
logsource:
  category: network_connection
  product: any
detection:
  selection:
      CommandLine|contains:
        - 'exploit'
  condition: selection
falsepositives:
  - Legitime administrative Zugriffe oder Penetrationstests
level: high
tags:
  - attack.initial_access
Syntax validiert (0 Fehler)
rule CTI_Threat_Indicator {
    meta:
        author = "iShareStuff CTI Automated Detection Engine"
        date = "2026-09-25"
        description = "YARA Signature for "
    strings:
        $str = "🚀 Building a GitOps Infrastruc" ascii wide
    condition:
        any of them
}
Syntax validiert (0 Fehler)
index=security sourcetype IN ("cisco:asa", "pan:traffic", "zeek_conn", "suricata", "WinEventLog:Security")
("Building a GitOps Infrastructure Pipelin")
| stats count earliest(_time) as first_seen latest(_time) as last_seen by src_ip, dest_ip, dest_host, signature
| eval first_seen=strftime(first_seen, "%Y-%m-%d %H:%M:%S"), last_seen=strftime(last_seen, "%Y-%m-%d %H:%M:%S")
| sort - count
Syntax validiert (0 Fehler)
message: "*Building a GitOps Infrastructure Pipelin*"
Syntax validiert (0 Fehler)
CommonSecurityLog
| where Message has "Building a GitOps Infrastructure Pipelin"
| summarize EventCount = count(), FirstSeen = min(TimeGenerated), LastSeen = max(TimeGenerated) by SourceIP, DestinationIP, DestinationPort, Activity
| extend DetectionRule = "iShareStuff-CTI-Compiled"
| sort by EventCount desc

2. Cyber Threat Intelligence & Forensik

CTI Threat Relationship Graph2 Knoten / 1 Relationen
CVE / Incident Software MITRE ATT&CK CWE Weakness IoC
🎯
MITRE ATT&CK Matrix Navigator 14 Taktiken
Reconnaissance
-
Resource Development
-
Initial Access
Execution
Persistence
-
Privilege Escalation
Defense Evasion
Credential Access
-
Discovery
-
Lateral Movement
-
Collection
-
Command and Control
Exfiltration
-
Impact
tsecurity.de Cognitive Threat RAG
Fokus-Vektor:

Kognitive Analyse für identifizierte Bedrohung: Erhöhte Bedrohungslage im Bereich 🚀 Building a GitOps Infrastructure Pipel.... Basierend auf 368k Vektor-Korrelationen werden sofortige Isolationsmaßnahmen für betroffene Endpunkte empfohlen.

🛡️ Angriffsfläche & Exposure

Netzwerk/Remote-Zugriff ohne Vorauthentifizierung möglich.

⚡ Empfohlene Sofortmaßnahmen
  • 1. Perimeter-Inspektion: Relevante Portfreigaben und exponierte Endpunkte unverzüglich scannen.
  • 2. Patch-Applikation: Hersteller-Hotfix einspielen oder betroffene Daemons in isolierte DMZ-Segmente überführen.
  • 3. Telemetrie & EDR-Alerts: Prozessaufrufe und Child-Processes auf anomale Shell-Spawns überwachen.
🔗 Semantisch verwandte Zero-Days MariaDB 11.7 VEC
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten 🚀 Building a GitOps Infrastructure Pipeline with Crossplane and Argo CD

Thematisch verwandte Begriffe: Building, GitOps, Infrastructure, Pipeline · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-97898 | Insecure Direct Object Reference / missing object-level authorization in…
Advisory →
tsecurity.de Icon
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag