Komari探针监控端Docker部署

起因

国内对于raw.githubusercontent.com的访问不是很友好,也找不到合适的镜像,于是就想到用Docker来运行

1Panel如何使用

在部署好komari后,打开容器,选择编排,然后点击创建,写入docker-compose内容保存后即可运行

使用了SuzukiRenz 的Docker镜像,配置稍做了修改,原本的配置无法正确获取存储空间,修改后的可以


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
services:
komari-agent:
image: suzukirenz/komari-agent:latest # 国内用户可以使用docker.1ms.run/suzukirenz/komari-agent:latest
container_name: komari-agent
restart: unless-stopped
network_mode: host # 使用主机网络,注意:host模式下ports映射不生效
volumes:
- /proc:/proc
- /sys:/sys:ro
- /dev:/dev:ro
- /etc/localtime:/etc/localtime:ro
- /etc/os-release:/etc/os-release:ro
command:
--endpoint "https://xxx.com" # 你的komari域名或者ip
--token "xxxxxxxxx" # 你的token
--disable-web-ssh
--disable-auto-update
--ignore-unsafe-cert

默认禁用远程控制,禁用自动更新,忽略不安全证书

参考文献