docs(agents): add Git + ArgoCD CLI checks to migration workflow
Adds "Agent Workflow Defaults" and "Commit & Push + ArgoCD CLI Checks" to AGENTS.md (via CLAUDE.md).\nStandardizes post-app-addition flow: commit/push, argocd login/sync/wait, and basic diagnostics.\n\nCommitted via Codex CLI.
This commit is contained in:
@@ -113,6 +113,12 @@ The kube-plex/ directory contains a Go application that replaces the standard Pl
|
|||||||
|
|
||||||
## ArgoCD Migration Guidelines
|
## ArgoCD Migration Guidelines
|
||||||
|
|
||||||
|
### Agent Workflow Defaults
|
||||||
|
When migrating or adding an ArgoCD Application, always:
|
||||||
|
- Create/update the Application manifest and any `helm-values/` files.
|
||||||
|
- Git add, commit, and push the changes to the tracked branch.
|
||||||
|
- Use the ArgoCD CLI to sync the app and wait for healthy status.
|
||||||
|
|
||||||
### Critical Configuration Preservation Rules
|
### Critical Configuration Preservation Rules
|
||||||
When migrating applications from direct Helm deployment to ArgoCD GitOps:
|
When migrating applications from direct Helm deployment to ArgoCD GitOps:
|
||||||
|
|
||||||
@@ -252,6 +258,42 @@ Before migrating any application to ArgoCD:
|
|||||||
helm template <app-name> <chart> --values <values-file> | grep -A 20 "kind: Service"
|
helm template <app-name> <chart> --values <values-file> | grep -A 20 "kind: Service"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Commit & Push + ArgoCD CLI Checks
|
||||||
|
After adding a new ArgoCD Application and values files:
|
||||||
|
|
||||||
|
1. Commit and push the changes:
|
||||||
|
```bash
|
||||||
|
git add applications/<app>.yaml helm-values/<app>_values.*
|
||||||
|
git commit -m "feat(argocd): add <app> application"
|
||||||
|
git push # or: git push gitea master
|
||||||
|
```
|
||||||
|
|
||||||
|
2. ArgoCD CLI login (if not already authenticated):
|
||||||
|
```bash
|
||||||
|
# Example options; adjust for your environment
|
||||||
|
# Get admin password if needed
|
||||||
|
kubectl -n argocd get secret argocd-initial-admin-secret -o jsonpath='{.data.password}' | base64 -d; echo
|
||||||
|
|
||||||
|
# Login (use your server/credentials)
|
||||||
|
argocd login argocd-server.argocd.svc.cluster.local --username admin --password <password> --insecure
|
||||||
|
```
|
||||||
|
|
||||||
|
3. Sync and wait for health:
|
||||||
|
```bash
|
||||||
|
argocd app sync <app>
|
||||||
|
argocd app wait <app> --sync --health --timeout 300
|
||||||
|
argocd app get <app>
|
||||||
|
argocd app list | grep <app>
|
||||||
|
```
|
||||||
|
|
||||||
|
4. If sync fails, inspect details and events:
|
||||||
|
```bash
|
||||||
|
argocd app history <app> --refresh
|
||||||
|
argocd app get <app> --refresh
|
||||||
|
kubectl -n default describe deploy/<app> || true
|
||||||
|
kubectl -n default get events --sort-by=.lastTimestamp | tail -n 50
|
||||||
|
```
|
||||||
|
|
||||||
### Post-Migration Verification
|
### Post-Migration Verification
|
||||||
|
|
||||||
1. **Check Volume Mounts Match Original**:
|
1. **Check Volume Mounts Match Original**:
|
||||||
|
|||||||
Reference in New Issue
Block a user