#1. 배포 아키텍처

GitHub
  ↓ (CI)
GitHub Actions
  ├─ Build Docker Image
  ├─ Run Tests
  ├─ Push → Container Registry (NCP CR / ECR / GHCR)
  └─ Commit updated manifest (tag update) to Git Repo
      ↓
ArgoCD (GitOps)
  ↓ (CD)
Kubernetes Cluster
  └─ runna-server Deployment (Pod)

#2. ArgoCD(CD)에서 해야 하는 일

ArgoCD는 k8s manifests가 있는 Git Repo를 watching.

apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: runna-server
  namespace: argocd
spec:
  project: default
  source:
    repoURL: <https://github.com/you/runna-manifest>
    path: runna-server
    targetRevision: main
  destination:
    name: ''
    namespace: default
    server: <https://kubernetes.default.svc>
  syncPolicy:
    automated:
      prune: true
      selfHeal: true

#4. runna-server 배포 리소스 구조 예시

⇒ argoCD가 보고 배포할 수 있도록

runna-manifest/
 └── runna-server/
     ├── deployment.yaml
     ├── service.yaml
     ├── ingress.yaml        # (있으면)
     └── configmap.yaml      # (필요하면)