Skip to content
Extraits de code Groupes Projets
Valider c98f9f06 rédigé par Théo - Le Filament's avatar Théo - Le Filament
Parcourir les fichiers

style: update linting rules and format code according to them

parent c120e2da
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -27,7 +27,7 @@ rules: ...@@ -27,7 +27,7 @@ rules:
indentation: indentation:
level: warning level: warning
indent-sequences: consistent indent-sequences: consistent
spaces: 4 spaces: 2
check-multi-line-strings: true check-multi-line-strings: true
key-duplicates: enable key-duplicates: enable
line-length: disable line-length: disable
......
--- ---
- name: Restart nagios docker - name: "Restart Nagios container"
community.docker.docker_compose: community.docker.docker_compose:
project_src: /home/docker/nagios/ project_src: "/home/docker/nagios/"
restarted: true restarted: true
listen: "restart nagios container"
--- ---
## Install Nagios docker ## Install Nagios docker
- name: Create Nagios docker structure on server in /home/docker/nagios - name: "Create Nagios docker structure on server in /home/docker/nagios"
ansible.builtin.file: ansible.builtin.file:
name: "{{ item }}" name: "{{ item }}"
state: directory state: directory
owner: '999' owner: "999"
group: '1000' group: "1000"
mode: '0755' mode: "0755"
with_items: with_items:
- /home/docker/nagios/etc/objects - "/home/docker/nagios/etc/objects"
- /home/docker/nagios/stylesheets - "/home/docker/nagios/stylesheets"
- name: Copy nagios docker-compose file - name: "Copy nagios docker-compose file"
ansible.builtin.template: ansible.builtin.template:
src: nagios.yaml.j2 src: "nagios.yaml.j2"
dest: /home/docker/nagios/docker-compose.yaml dest: "/home/docker/nagios/docker-compose.yaml"
mode: '0644' mode: "0644"
notify: Restart nagios docker notify: "restart nagios container"
- name: Copy configuration files - name: "Copy configuration files"
tags:
- "nagios_config"
ansible.builtin.copy: ansible.builtin.copy:
src: "{{ item }}" src: "{{ item }}"
dest: /home/docker/nagios/etc/{{ item }} dest: "/home/docker/nagios/etc/{{ item }}"
mode: '0644' mode: "0644"
owner: '999' owner: "999"
group: '1000' group: "1000"
with_items: with_items:
- cgi.cfg - "cgi.cfg"
- nagios.cfg - "nagios.cfg"
- resource.cfg - "resource.cfg"
notify: Restart nagios docker notify: "restart nagios container"
tags: nagios_config
- name: Copy CSS files - name: "Copy CSS files"
tags:
- "nagios_style"
ansible.builtin.copy: ansible.builtin.copy:
src: "{{ item }}" src: "{{ item }}"
dest: /home/docker/nagios/stylesheets/{{ item }} dest: "/home/docker/nagios/stylesheets/{{ item }}"
mode: '0644' mode: "0644"
owner: '999' owner: "999"
group: '1000' group: "1000"
with_items: with_items:
- avail.css - "avail.css"
- checksanity.css - "checksanity.css"
- cmd.css - "cmd.css"
- common.css - "common.css"
- config.css - "config.css"
- extinfo.css - "extinfo.css"
- histogram.css - "histogram.css"
- histogramgraph.css - "histogramgraph.css"
- history.css - "history.css"
- jsonquery.css - "jsonquery.css"
- map.css - "map.css"
- map-directive.css - "map-directive.css"
- ministatus.css - "ministatus.css"
- nag_funcs.css - "nag_funcs.css"
- notifications.css - "notifications.css"
- outages.css - "outages.css"
- showlog.css - "showlog.css"
- status.css - "status.css"
- statusmap.css - "statusmap.css"
- summary.css - "summary.css"
- tac.css - "tac.css"
- trends.css - "trends.css"
- trendsgraph.css - "trendsgraph.css"
notify: Restart nagios docker notify: "restart nagios docker"
tags: nagios_config
- name: Copy objects configuration files - name: "Copy objects configuration files"
tags:
- "nagios_config"
ansible.builtin.template: ansible.builtin.template:
src: "{{ item }}.j2" src: "{{ item }}.j2"
dest: /home/docker/nagios/etc/objects/{{ item }} dest: "/home/docker/nagios/etc/objects/{{ item }}"
mode: '0644' mode: "0644"
owner: '999' owner: "999"
group: '1000' group: "1000"
with_items: with_items:
- vps.cfg - "vps.cfg"
- localhost.cfg - "localhost.cfg"
- templates.cfg - "templates.cfg"
- contacts.cfg - "contacts.cfg"
- commands.cfg - "commands.cfg"
- timeperiods.cfg - "timeperiods.cfg"
notify: Restart nagios docker notify: "restart nagios container"
tags: nagios_config
- name: Create apache2 dir on server in /home/docker/nagios - name: "Create apache2 dir on server in /home/docker/nagios"
tags:
- "nagios_webserver"
ansible.builtin.file: ansible.builtin.file:
name: /home/docker/nagios/apache2 name: "/home/docker/nagios/apache2"
owner: 'root' owner: "root"
group: 'root' group: "root"
mode: '0755' mode: "0755"
state: directory state: directory
- name: Install apache2 configuration files - name: "Install apache2 configuration files"
tags:
- "nagios_webserver"
ansible.builtin.copy: ansible.builtin.copy:
src: "{{ item }}" src: "{{ item }}"
dest: /home/docker/nagios/apache2/{{ item }} dest: "/home/docker/nagios/apache2/{{ item }}"
mode: '0644' mode: "0644"
with_items: with_items:
- 000-default.conf - "000-default.conf"
- nagios.conf - "nagios.conf"
notify: Restart nagios docker notify: "restart nagios container"
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter