52 lines
1.4 KiB
YAML
Executable File
52 lines
1.4 KiB
YAML
Executable File
---
|
|
- name: Setup Netdata
|
|
|
|
hosts: all
|
|
|
|
vars_files:
|
|
- vault.yaml
|
|
- vars.yaml
|
|
|
|
tasks:
|
|
- name: Run Netdata container
|
|
docker_container:
|
|
name: "{{ stack_prefix_name }}netdata"
|
|
recreate: true
|
|
restart_policy: unless-stopped
|
|
image: netdata/netdata:1.34
|
|
hostname: monitor.gopoop.org
|
|
capabilities:
|
|
- SYS_PTRACE
|
|
security_opts:
|
|
- apparmor=unconfined
|
|
networks:
|
|
- name: "{{ stack_prefix_name }}{{ docker_internal_network }}"
|
|
env:
|
|
PGID: "998"
|
|
mounts:
|
|
- source: /var/run/docker.sock
|
|
target: /var/run/docker.sock:ro
|
|
type: bind
|
|
- target: /etc/netdata:ro
|
|
source: /home/server/netdataconfig/netdata
|
|
type: bind
|
|
- target: /var/lib/netdata
|
|
source: "{{ stack_prefix_name }}netdatalib"
|
|
- target: /var/cache/netdata
|
|
source: "{{ stack_prefix_name }}netdatacache"
|
|
- target: /host/etc/passwd:ro
|
|
source: /etc/passwd
|
|
type: bind
|
|
- target: /host/etc/group:ro
|
|
source: /etc/group
|
|
type: bind
|
|
- target: /host/proc:ro
|
|
source: /proc
|
|
type: bind
|
|
- target: /host/sys:ro
|
|
source: /sys
|
|
type: bind
|
|
- target: /host/etc/os-release:ro
|
|
source: /etc/os-release
|
|
type: bind
|