File tree Expand file tree Collapse file tree 2 files changed +61
-23
lines changed
Expand file tree Collapse file tree 2 files changed +61
-23
lines changed Original file line number Diff line number Diff line change 1+ name : Sync to CNB
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+ # 可以手动触发
8+ workflow_dispatch :
9+ inputs :
10+ logLevel :
11+ description : " Log level"
12+ required : true
13+ default : " warning"
14+ tags :
15+ description : " Test scenario tags"
16+
17+ jobs :
18+ sync :
19+ runs-on : ubuntu-latest
20+ steps :
21+ - uses : actions/checkout@v6
22+ with :
23+ fetch-depth : 0
24+
25+ - name : Sync to CNB Repository
26+ run : |
27+ docker run --rm \
28+ -v ${{ github.workspace }}:${{ github.workspace }} \
29+ -w ${{ github.workspace }} \
30+ -e PLUGIN_TARGET_URL="https://cnb.cool/opsre/cloud_dns_exporter.git" \
31+ -e PLUGIN_AUTH_TYPE="https" \
32+ -e PLUGIN_USERNAME="cnb" \
33+ -e PLUGIN_PASSWORD=${{ secrets.CNB_TOKEN }} \
34+ -e PLUGIN_BRANCH="main" \
35+ -e PLUGIN_GIT_USER="cnb" \
36+ -e PLUGIN_GIT_EMAIL="cnb@cnb.cool" \
37+ -e PLUGIN_FORCE="true" \
38+ tencentcom/git-sync
Original file line number Diff line number Diff line change 1- version : ' 3'
21services :
32 cloud_dns_exporter :
43 image : registry.cn-hangzhou.aliyuncs.com/eryajf/cloud_dns_exporter:latest
@@ -10,28 +9,29 @@ services:
109 target : /app/config.yaml
1110 environment :
1211 - TZ=Asia/Shanghai
13- grafana :
14- image : bitnami/grafana:11.2.0
15- container_name : grafana
16- environment :
17- - GF_SECURITY_ADMIN_PASSWORD=admin # 设置admin用户默认密码
18- - TZ=Asia/Shanghai
19- ports :
20- - " 3000:3000"
21- volumes :
22- - grafana_data:/opt/bitnami/grafana/data
23- prometheus :
24- image : bitnami/prometheus:2.54.1
25- container_name : prometheus
26- environment :
27- - TZ=Asia/Shanghai
28- ports :
29- - " 9090:9090"
30- configs :
31- - source : prometheus_config
32- target : /opt/bitnami/prometheus/conf/prometheus.yml
33- volumes :
34- - prometheus_data:/opt/bitnami/prometheus/data
12+ # 以下为可选监控组件,如需使用请取消注释
13+ # grafana:
14+ # image: bitnami/grafana:11.2.0
15+ # container_name: grafana
16+ # environment:
17+ # - GF_SECURITY_ADMIN_PASSWORD=admin #设置admin用户默认密码
18+ # - TZ=Asia/Shanghai
19+ # ports:
20+ # - "3000:3000"
21+ # volumes:
22+ # - grafana_data:/opt/bitnami/grafana/data
23+ # prometheus:
24+ # image: bitnami/prometheus:2.54.1
25+ # container_name: prometheus
26+ # environment:
27+ # - TZ=Asia/Shanghai
28+ # ports:
29+ # - "9090:9090"
30+ # configs:
31+ # - source: prometheus_config
32+ # target: /opt/bitnami/prometheus/conf/prometheus.yml
33+ # volumes:
34+ # - prometheus_data:/opt/bitnami/prometheus/data
3535
3636# 示例配置
3737configs :
You can’t perform that action at this time.
0 commit comments