Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add amamba components dashboard #5966

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
164 changes: 164 additions & 0 deletions docs/zh/docs/amamba/components-grafana-dashboard.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
# 应用工作台组件的可观测面板

本文提供了应用工作台中相关组件如何开启 Grafana 面板的方法,便于监控相关组件的关键指标。应用工作台中的组件包括:

- Jenkins
- ArgoCD
- Argo Rollouts
- KubeVela

默认情况下并不会开启这些组件的指标采集能力,需要手动开启,各个组件的开启方法如下。

## Jenkins

!!! note

Jenkins 版本需要 >= v0.4.7

需要通过更新 Helm 参数的方式开启,具体方式如下:

1. 前往 **容器管理** ,点击 **集群列表** ,找到 Jenkins 所在的集群
2. 点击 **Helm 应用** ,找到 Jenkins 所在的命名空间。找到 Jenkins 后,点击 **更新**
3. 选择通过 YAML 的形式更新,待修改的 YAML 字段如下:

```yaml
jenkins:
Master:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
```

4. 点击**保存** ,等待 3 分钟左右
5. 前往 **可观测性** ,点击 **仪表盘** ,在仪表盘中搜索关键字 `jenkins` 即可打开仪表盘

## ArgoCD

ArgoCD 也是通过更新 Helm 参数的方式开启,通过 Helm 更新的步骤与[上述 Jenkins 的步骤](#jenkins)一致,关键字搜索 `argocd`。
待修改的 YAML 字段如下:

```yaml
argo-cd:
controller:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
dex:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
redis:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
server:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
repoServer:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
notifications:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
applicationSet:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
```

### argo-rollouts

argo-rollouts 也是通过更新 Helm 参数的方式开启,通过 Helm 更新的步骤与[上述 Jenkins 的步骤](#jenkins)一致,关键字搜索argo-rollouts。
待修改的 YAML 字段如下:

```yaml
argo-rollouts:
controller:
metrics:
enabled: true
serviceMonitor:
enabled: true
additionalLabels:
operator.insight.io/managed-by: insight
```

### KubeVela

KubeVela **不支持** 直接通过设置参数的方式开启可观测能力。目前需要手动部署以下资源:

1. 部署 Service

```yaml
apiVersion: v1
kind: Service
metadata:
name: kubevela-controller-service
namespace: < your kubevela namespace > # 需要替换
labels:
component: kubevela-controller
spec:
ports:
- name: http
protocol: TCP
port: 9443
targetPort: 9443
- name: metrics
protocol: TCP
port: 8080
targetPort: 8080
selector: < kubevela core pod label selector> # 需要替换
```

2. 部署 ServiceMonitor

```yaml
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: amamba-kubevela
namespace: < your kubevela namespace > # 需要替换
labels:
operator.insight.io/managed-by: insight
spec:
endpoints:
- honorLabels: true
interval: 10s
path: /metrics
port: metrics
scheme: http
namespaceSelector:
matchNames:
- < your kubevela namespace > # 需要替换
selector:
matchLabels:
component: kubevela-controller
```

注意需要替换成实际的 namespace、labelSelector。打开仪表板的方式与上述 Jenkins、ArgoCD 等其他组件一致。
1 change: 1 addition & 0 deletions docs/zh/navigation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ nav:
- Jenkins 高可用方案: amamba/quickstart/jenkins-HA.md
- Jenkins 场景配置: amamba/quickstart/scenarios-config.md
- Argo CD高可用部署: amamba/quickstart/argo-cd-HA.md
- 开启工作台组件的可观测能力: amamba/components-grafana-dashboard.md
- 命名空间管理:
- 命名空间: amamba/user-guide/namespace/namespace.md
- 多云命名空间: amamba/user-guide/multi-namespace.md
Expand Down
Loading