First commit for npg stack
This commit is contained in:
parent
ad3f8bc031
commit
1919071f08
1
netdata-grafana-prometheus-stack/.env.template
Normal file
1
netdata-grafana-prometheus-stack/.env.template
Normal file
@ -0,0 +1 @@
|
|||||||
|
COMPOSE_PROJECT_NAME=npg
|
||||||
0
netdata-grafana-prometheus-stack/README.md
Normal file
0
netdata-grafana-prometheus-stack/README.md
Normal file
98
netdata-grafana-prometheus-stack/docker-compose.yml
Normal file
98
netdata-grafana-prometheus-stack/docker-compose.yml
Normal file
@ -0,0 +1,98 @@
|
|||||||
|
---
|
||||||
|
x-logging: &default-logging
|
||||||
|
driver: local
|
||||||
|
options:
|
||||||
|
max-size: "1m"
|
||||||
|
max-file: "50"
|
||||||
|
|
||||||
|
x-opt-values: &volume-opt
|
||||||
|
driver_opts: &options
|
||||||
|
type: "nfs"
|
||||||
|
o: "addr=${IP},rw"
|
||||||
|
|
||||||
|
services:
|
||||||
|
# https://learn.netdata.cloud/docs/agent/packaging/docker
|
||||||
|
# https://learn.netdata.cloud/docs/agent/exporting/walkthrough
|
||||||
|
netdata:
|
||||||
|
image: netdata/netdata
|
||||||
|
container_name: netdata
|
||||||
|
hostname: netdata.domain.tld # set to fqdn of host
|
||||||
|
env_file:
|
||||||
|
- netdata.env
|
||||||
|
restart: unless-stopped
|
||||||
|
cap_add:
|
||||||
|
- SYS_PTRACE
|
||||||
|
security_opt:
|
||||||
|
- apparmor:unconfined
|
||||||
|
volumes:
|
||||||
|
- netdataconfig:/etc/netdata:ro
|
||||||
|
- netdatalib:/var/lib/netdata
|
||||||
|
- netdatacache:/var/cache/netdata
|
||||||
|
- /etc/passwd:/host/etc/passwd:ro
|
||||||
|
- /etc/group:/host/etc/group:ro
|
||||||
|
- /proc:/host/proc:ro
|
||||||
|
- /sys:/host/sys:ro
|
||||||
|
- /etc/os-release:/host/etc/os-release:ro
|
||||||
|
- /var/run/docker.sock:/var/run/docker.sock:ro
|
||||||
|
networks:
|
||||||
|
- reverse-proxy
|
||||||
|
- npg
|
||||||
|
logging: *default-logging
|
||||||
|
|
||||||
|
prometheus:
|
||||||
|
image: prom/prometheus
|
||||||
|
container_name: prometheus
|
||||||
|
hostname: prometheus
|
||||||
|
env_file:
|
||||||
|
prometheus.env
|
||||||
|
volumes:
|
||||||
|
- prometheus:/etc/prometheus
|
||||||
|
networks:
|
||||||
|
- npg
|
||||||
|
logging: *default-logging
|
||||||
|
|
||||||
|
grafana:
|
||||||
|
image: grafana/grafana
|
||||||
|
container_name: grafana
|
||||||
|
env_file:
|
||||||
|
grafana.env
|
||||||
|
volumes:
|
||||||
|
- grafana:/var/lib/grafana
|
||||||
|
networks:
|
||||||
|
- npg
|
||||||
|
logging: *default-logging
|
||||||
|
|
||||||
|
# Can be substituted by a standard volume declaration if it's just a test
|
||||||
|
# environment or no nfs server is available
|
||||||
|
volumes:
|
||||||
|
netdataconfig:
|
||||||
|
<<: *volume-opt
|
||||||
|
driver_opts:
|
||||||
|
<<: *options
|
||||||
|
device: ":/mnt/path/netdata/netdataconfig"
|
||||||
|
netdatalib:
|
||||||
|
<<: *volume-opt
|
||||||
|
driver_opts:
|
||||||
|
<<: *options
|
||||||
|
device: ":/mnt/path/netdata/netdatalib"
|
||||||
|
netdatacache:
|
||||||
|
<<: *volume-opt
|
||||||
|
driver_opts:
|
||||||
|
<<: *options
|
||||||
|
device: ":/mnt/path/netdata/netdatacache"
|
||||||
|
prometheus:
|
||||||
|
<<: *volume-opt
|
||||||
|
driver_opts:
|
||||||
|
<<: *options
|
||||||
|
device: ":/mnt/path/prometheus/prometheus"
|
||||||
|
grafana:
|
||||||
|
<<: *volume-opt
|
||||||
|
driver_opts:
|
||||||
|
<<: *options
|
||||||
|
device: ":/mnt/path/grafana/grafana"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
reverse-proxy:
|
||||||
|
name: rp_reverse-proxy
|
||||||
|
external: true
|
||||||
|
npg:
|
||||||
3
netdata-grafana-prometheus-stack/grafana.env.template
Normal file
3
netdata-grafana-prometheus-stack/grafana.env.template
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
VIRTUAL_HOST="grafana.domain.tld"
|
||||||
|
VIRTUAL_PORT=3000
|
||||||
|
LETSENCRYPT_HOST="grafana.domain.tld"
|
||||||
6
netdata-grafana-prometheus-stack/netdata.env.template
Normal file
6
netdata-grafana-prometheus-stack/netdata.env.template
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
VIRTUAL_HOST="netdata.domain.tld"
|
||||||
|
VIRTUAL_PORT=19999
|
||||||
|
LETSENCRYPT_HOST="netdata.domain.tld"
|
||||||
|
NETDATA_CLAIM_TOKEN=hOOww34Yc-6vYBYxRKBop6Ozbsf0B2WSaPBTsW_mbHuBYiHcGDVsvbqETz5SaevMvOVBK_4r7q6WwLZTTD3iwHy2T2X1NsRExqUWWUn3LQXDGYlvKKCynVRafuNT9xmH1cuQ0l8
|
||||||
|
NETDATA_CLAIM_URL=https://app.netdata.cloud
|
||||||
|
NETDATA_CLAIM_ROOMS=
|
||||||
5
netdata-grafana-prometheus-stack/nginx.conf
Normal file
5
netdata-grafana-prometheus-stack/nginx.conf
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
# File that has to be put under /etc/netdata/go.d/nginx.conf to monitor
|
||||||
|
# nginx_status
|
||||||
|
jobs:
|
||||||
|
- name: local
|
||||||
|
url: http://nginx-proxy/nginx_status
|
||||||
3
netdata-grafana-prometheus-stack/prometheus.env.template
Normal file
3
netdata-grafana-prometheus-stack/prometheus.env.template
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
VIRTUAL_HOST="prometheus.domain.tld"
|
||||||
|
VIRTUAL_PORT=9090
|
||||||
|
LETSENCRYPT_HOST="prometheus.domain.tld"
|
||||||
Loading…
x
Reference in New Issue
Block a user