mirror of https://github.com/nicolargo/glances
Please add docker-compose example and document example. #2151
parent
94d1e00692
commit
5511bbfd83
|
@ -1,3 +1,3 @@
|
|||
FROM nicolargo/glances:dev
|
||||
FROM nicolargo/glances:alpine-dev
|
||||
COPY glances.conf /glances/conf/glances.conf
|
||||
CMD python -m glances -C /glances/conf/glances.conf $GLANCES_OPT
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
version: "3.9"
|
||||
services:
|
||||
reverse-proxy:
|
||||
image: traefik
|
||||
command: --api --docker
|
||||
ports:
|
||||
- "80:80"
|
||||
- "8080:8080"
|
||||
volumes:
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
|
||||
whoami:
|
||||
image: emilevauge/whoami
|
||||
labels:
|
||||
- "traefik.frontend.rule=Host:whoami.docker.localhost"
|
||||
|
||||
monitoring:
|
||||
image: nicolargo/glances:alpine-dev
|
||||
restart: unless-stopped
|
||||
pid: host
|
||||
privileged: true
|
||||
network_mode: "host"
|
||||
volumes:
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
environment:
|
||||
- "GLANCES_OPT=-w"
|
||||
labels:
|
||||
- "traefik.port=61208"
|
||||
- "traefik.frontend.rule=Host:glances.docker.localhost"
|
|
@ -1,4 +1,4 @@
|
|||
version: '3.7'
|
||||
version: '3.9'
|
||||
services:
|
||||
glances:
|
||||
build:
|
||||
|
@ -13,3 +13,5 @@ services:
|
|||
- "/var/run/docker.sock:/var/run/docker.sock:ro"
|
||||
- "./glances.conf:/glances/conf/glances.conf"
|
||||
pid: "host"
|
||||
privileged: true
|
||||
network_mode: "host"
|
||||
|
|
Loading…
Reference in New Issue