feat: use Alpine AOT images, static SQLite and Podman host metrics [CI]
This commit is contained in:
1 parent
6e945657c1
commit
103ef27ed3
37 files changed
+719
-309
No files matched your search
@@ -7,7 +7,8 @@
|
||||
# --server "$MONITOR_SERVER" --join "$MONITOR_JOIN_TOKEN" --name "$MONITOR_AGENT_NAME" --identity-dir /etc/monitor/agent-id
|
||||
# 再在 .data/agent.json 里写(fleet.identity_dir 要和上面一致):
|
||||
# {"fleet":{"server":"https://<backend>","identity_dir":"/etc/monitor/agent-id"},"listen":{"bind":"0.0.0.0"},"limits":{"max_total_mbps":100,"max_total_pps":10000}}
|
||||
# docker compose up -d
|
||||
# sudo chown -R 1654:1654 .data
|
||||
# sudo podman compose up -d # Linux rootful Podman;也可用 docker compose
|
||||
#
|
||||
# 更新:改 MONITOR_VERSION(或 MONITOR_IMAGE),再 docker compose pull && docker compose up -d。
|
||||
# 这种方式没有宿主机更新器:管理端的「更新」按钮对它不起作用;要自动更新请用 podman + systemd(docs/deployment.md「容器节点的运行」)。.data 不动,身份和历史都保留。
|
||||
@@ -21,11 +22,20 @@ services:
|
||||
network_mode: host
|
||||
volumes:
|
||||
- ./.data:/etc/monitor
|
||||
- /etc/os-release:/etc/os-release:ro # 让节点读到宿主机的系统名(镜像里是 Ubuntu)
|
||||
- /etc/os-release:/etc/os-release:ro
|
||||
# 系统目录只读,不加 :z/:Z;SELinux 隔离在容器级别禁用。
|
||||
- /proc:/host/proc:ro
|
||||
- /sys:/host/sys:ro
|
||||
- /:/host/root:ro
|
||||
environment:
|
||||
HOST_PROC: /host/proc
|
||||
HOST_SYS: /host/sys
|
||||
HOST_ROOT: /host/root
|
||||
read_only: true
|
||||
tmpfs:
|
||||
- /tmp:rw,noexec,nosuid,size=64m,mode=1777
|
||||
security_opt:
|
||||
- label=disable
|
||||
- no-new-privileges:true
|
||||
cap_drop:
|
||||
- ALL
|
||||
|
||||
Reference in new issue
Block a user