asd
Some checks failed
CI/CD Pipeline / lint (push) Failing after 57s
CI/CD Pipeline / deploy (push) Failing after 1m21s

This commit is contained in:
sotos
2025-12-18 15:29:47 +01:00
parent bb88b190ee
commit 5940099978
6 changed files with 91 additions and 46 deletions

View File

@@ -1,21 +1,33 @@
---
- hosts: all
become: true
vars:
monitor_dir: /opt/docker/monitoring
docker_network: monitoring
tasks:
- name: Create monitoring directory
- name: Ensure monitoring directory exists
file:
path: "{{ monitor_dir }}"
state: directory
owner: root
group: root
mode: '0755'
- name: Copy monitoring stack
copy:
src: ../../docker/monitoring/
dest: "{{ monitor_dir }}"
owner: root
group: root
mode: '0755'
- name: Start monitoring
command: docker compose up -d
args:
chdir: "{{ monitor_dir }}"
- name: Ensure monitoring Docker network exists
docker_network:
name: "{{ docker_network }}"
state: present
- name: Start monitoring stack
docker_container:
project_src: "{{ monitor_dir }}"
state: present
restarted: true