gitops-status
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseGitOps Status
GitOps状态监控
Monitor GitOps application health and manage sync operations via MCP.
通过MCP监控GitOps应用健康状态并管理同步操作。
Instructions
操作说明
Step 1: Overview Dashboard
步骤1:概览仪表板
Call MCP tool: harness_get
Parameters:
resource_type: "gitops_dashboard"Call MCP tool: harness_get
Parameters:
resource_type: "gitops_dashboard"Step 2: List Applications
步骤2:列出应用
Call MCP tool: harness_list
Parameters:
resource_type: "gitops_application"
org_id: "<organization>"
project_id: "<project>"Call MCP tool: harness_list
Parameters:
resource_type: "gitops_application"
org_id: "<organization>"
project_id: "<project>"Step 3: Get Application Details
步骤3:获取应用详情
Call MCP tool: harness_get
Parameters:
resource_type: "gitops_application"
resource_id: "<app_name>"
org_id: "<organization>"
project_id: "<project>"Call MCP tool: harness_get
Parameters:
resource_type: "gitops_application"
resource_id: "<app_name>"
org_id: "<organization>"
project_id: "<project>"Step 4: Check Resource Tree
步骤4:查看资源树
Call MCP tool: harness_get
Parameters:
resource_type: "gitops_app_resource_tree"
resource_id: "<app_name>"Call MCP tool: harness_get
Parameters:
resource_type: "gitops_app_resource_tree"
resource_id: "<app_name>"Step 5: Get Pod Logs (Debugging)
步骤5:获取Pod日志(调试用)
Call MCP tool: harness_get
Parameters:
resource_type: "gitops_pod_log"
resource_id: "<pod_name>"Call MCP tool: harness_get
Parameters:
resource_type: "gitops_pod_log"
resource_id: "<pod_name>"Step 6: Check Events
步骤6:查看事件
Call MCP tool: harness_list
Parameters:
resource_type: "gitops_app_event"Call MCP tool: harness_list
Parameters:
resource_type: "gitops_app_event"Step 7: Trigger Sync
步骤7:触发同步
Call MCP tool: harness_execute
Parameters:
resource_type: "gitops_application"
action: "sync"
resource_id: "<app_name>"
org_id: "<organization>"
project_id: "<project>"Call MCP tool: harness_execute
Parameters:
resource_type: "gitops_application"
action: "sync"
resource_id: "<app_name>"
org_id: "<organization>"
project_id: "<project>"Additional Resource Types
其他资源类型
Call MCP tool: harness_list
Parameters:
resource_type: "gitops_agent" # ArgoCD agents
resource_type: "gitops_cluster" # Connected clusters
resource_type: "gitops_repository" # Git repositories
resource_type: "gitops_applicationset" # ApplicationSets
resource_type: "gitops_managed_resource" # K8s resourcesCall MCP tool: harness_list
Parameters:
resource_type: "gitops_agent" # ArgoCD代理
resource_type: "gitops_cluster" # 已连接集群
resource_type: "gitops_repository" # Git仓库
resource_type: "gitops_applicationset" # ApplicationSets
resource_type: "gitops_managed_resource" # K8s资源GitOps Resource Types
GitOps资源类型
| Resource Type | Operations | Description |
|---|---|---|
| list, get | ArgoCD instances |
| list, get, sync | Applications |
| list, get | ApplicationSets |
| list, get | K8s clusters |
| list, get | Git repositories |
| list | Application events |
| get | Pod logs |
| list | K8s resources |
| get | Resource tree |
| get | Overview dashboard |
| 资源类型 | 操作 | 描述 |
|---|---|---|
| list、get | ArgoCD实例 |
| list、get、sync | 应用 |
| list、get | ApplicationSets |
| list、get | K8s集群 |
| list、get | Git仓库 |
| list | 应用事件 |
| get | Pod日志 |
| list | K8s资源 |
| get | 资源树 |
| get | 概览仪表板 |
Application Health States
应用健康状态
- Healthy - All resources running and passing health checks
- Degraded - Some resources failing health checks
- Progressing - Resources being created/updated
- Suspended - Application suspended
- Missing - Resources not found
- Unknown - Health status cannot be determined
- Healthy(健康) - 所有资源正常运行且通过健康检查
- Degraded(退化) - 部分资源健康检查失败
- Progressing(进行中) - 资源正在创建/更新
- Suspended(暂停) - 应用已暂停
- Missing(缺失) - 未找到资源
- Unknown(未知) - 无法确定健康状态
Sync States
同步状态
- Synced - Live state matches desired state in Git
- OutOfSync - Live state differs from Git (needs sync)
- Unknown - Sync status cannot be determined
- Synced(已同步) - 实时状态与Git中的期望状态一致
- OutOfSync(不同步) - 实时状态与Git存在差异(需要同步)
- Unknown(未知) - 无法确定同步状态
Examples
使用示例
- "Show me all GitOps applications" - List gitops_application
- "Is the api-gateway in sync?" - Get gitops_application, check sync status
- "Sync the payment-service" - Execute sync action
- "Get pod logs for failing service" - Get gitops_pod_log
- "Show the resource tree for my app" - Get gitops_app_resource_tree
- “展示所有GitOps应用” - 列出gitops_application
- “api-gateway是否已同步?” - 获取gitops_application,检查同步状态
- “同步payment-service” - 执行sync操作
- “获取故障服务的Pod日志” - 获取gitops_pod_log
- “展示我的应用资源树” - 获取gitops_app_resource_tree
Performance Notes
性能注意事项
- Check all applications in the requested scope before summarizing health status.
- For out-of-sync applications, examine the resource tree to identify the specific drift.
- Gather pod logs for failing resources before diagnosing issues.
- 在汇总健康状态前,检查请求范围内的所有应用。
- 对于不同步的应用,检查资源树以识别具体差异。
- 在诊断问题前,收集故障资源的Pod日志。
Troubleshooting
故障排查
Application OutOfSync
应用不同步
- Check git repo for recent changes
- Verify auto-sync is enabled if expected
- Review sync errors in events
- Trigger manual sync if needed
- 检查Git仓库近期变更
- 若预期自动同步,验证是否已启用
- 查看事件中的同步错误
- 必要时触发手动同步
Application Degraded
应用状态退化
- Check pod logs for application errors
- Review resource tree for failing pods
- Check resource limits and quotas
- 检查Pod日志中的应用错误
- 查看资源树中的故障Pod
- 检查资源限制与配额
Agent Not Connected
代理未连接
- Verify ArgoCD agent is running
- Check network connectivity
- Review agent configuration
- 验证ArgoCD代理是否正在运行
- 检查网络连通性
- 查看代理配置