0%

harbor-ha

Harbor配置主从同步,同步状态监控

配置主从

仓库管理

复制管理

主从检测

站点监控

1
2
https://harbor.zhaohongye.com/
https://harbor-slave.zhaohongye.com/

检测脚本

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import requests
username = ""
password = ""
payload = {
'page': 1,
'page_size': 10,
'policy_id': 1
}
api_url = "https://harbor.zhaohongye.com/api/v2.0/replication/executions"
r = requests.get(api_url, params=payload, auth=(username,password))
if r.status_code == 200:
result_list = []
for i in r.json():
if i['status'] != "Succeed":
print('error')
print('ok')