From 9334078987485d78c514b092ef25c3a628e5d99f Mon Sep 17 00:00:00 2001 From: syropiatovvv Date: Mon, 8 Dec 2025 12:44:03 +0300 Subject: [PATCH] =?UTF-8?q?lab=5F4=20=D0=B4=D0=BE=20=D0=B8=D0=BD=D1=82?= =?UTF-8?q?=D0=B5=D0=B3=D1=80=D0=B0=D1=86=D0=B8=D0=B8=20grafana?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 2 ++ services/compose.env.template | 2 ++ services/compose.yaml | 22 ++++++++++++++++++++++ 3 files changed, 26 insertions(+) create mode 100644 services/compose.env.template diff --git a/.gitignore b/.gitignore index a904a6f..329ae7e 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,5 @@ __pycache__/ # virtual environments .venv/ .venv*/ +# .env files +*.env diff --git a/services/compose.env.template b/services/compose.env.template new file mode 100644 index 0000000..1b48124 --- /dev/null +++ b/services/compose.env.template @@ -0,0 +1,2 @@ +GF_SECURITY_ADMIN_USER=admin +GF_SECURITY_ADMIN_PASSWORD=admin diff --git a/services/compose.yaml b/services/compose.yaml index 09c5f6c..9a2ec42 100644 --- a/services/compose.yaml +++ b/services/compose.yaml @@ -24,3 +24,25 @@ services: - "--config.file=/etc/prometheus/prometheus.yaml" volumes: - "./prometheus/prometheus.yaml:/etc/prometheus/prometheus.yaml:ro" + + grafana: + image: grafana/grafana:12.4.0-20012734117 + ports: + - "3000:3000" + #environment: + # GF_SECURITY_ADMIN_USER: "$__file{/run/secrets/grafana-admin-user}" + # GF_SECURITY_ADMIN_PASSWORD: "$__file{/run/secrets/grafana-admin-password}" + #secrets: + # - grafana-admin-user + # - grafana-admin-password + environment: + GF_SECURITY_ADMIN_USER: "${GF_SECURITY_ADMIN_USER}" + GF_SECURITY_ADMIN_PASSWORD: "${GF_SECURITY_ADMIN_PASSWORD}" + +#secrets: +# +# grafana-admin-user: +# environment: GF_SECURITY_ADMIN_USER +# +# grafana-admin-password: +# environment: GF_SECURITY_ADMIN_PASSWORD