commit 3e832b597a6bdeea1acd24d8f6a7de6307986393
Author: Nicolas Chauvet <kwizart(a)gmail.com>
Date: Fri Jun 23 11:18:30 2023 +0200
Update virthost
playbooks/groups/virthost.yml | 37 +++++++++++++++++++------------------
1 files changed, 19 insertions(+), 18 deletions(-)
---
diff --git a/playbooks/groups/virthost.yml b/playbooks/groups/virthost.yml
index fcf2889..1e9b8d8 100644
--- a/playbooks/groups/virthost.yml
+++ b/playbooks/groups/virthost.yml
@@ -1,38 +1,39 @@
+---
# create a new virthost server system
# NOTE: should be used with --limit most of the time
# NOTE: most of these vars_path come from group_vars/backup_server or from hostvars
-- import_playbook: "/srv/web/infra/ansible/playbooks/include/happy_birthday.yml
myhosts=virthost:bvirthost:buildvmhost:virthost_comm:colo_virt:virthost_communishift
+- import_playbook: "/srv/web/infra/ansible/playbooks/include/happy_birthday.yml
myhosts=virthost:bvirthost:buildvmhost:virthost_comm:colo_virt:virthost_communishift"
- name: make virthost server system
hosts: virthost:bvirthost:buildvmhost:virthost_comm:colo_virt:virthost_communishift
user: root
- gather_facts: True
+ gather_facts: true
vars_files:
- /srv/web/infra/ansible/vars/global.yml
- - "/srv/private/ansible/vars.yml"
+ - /srv/private/ansible/vars.yml
- /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml
pre_tasks:
- - include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
- - import_tasks: "{{ tasks_path }}/yumrepos.yml"
+ - include_vars: dir=/srv/web/infra/ansible/vars/all/ ignore_files=README
+ - import_tasks: "{{ tasks_path }}/yumrepos.yml"
roles:
- - base
- - rkhunter
- - nagios_client
- - hosts
- - fas_client
- - collectd/base
- - { role: iscsi_client, when: datacenter == "online" }
- - sudo
- - { role: openvpn/client, when: datacenter != "online" }
- - virthost
+ - base
+ - rkhunter
+ - nagios_client
+ - hosts
+ - fas_client
+ - collectd/base
+ - {role: iscsi_client, when: datacenter == "online"}
+ - sudo
+ - {role: openvpn/client, when: datacenter != "online"}
+ - virthost
tasks:
- - import_tasks: "{{ tasks_path }}/2fa_client.yml"
- - import_tasks: "{{ tasks_path }}/motd.yml"
+ - import_tasks: "{{ tasks_path }}/2fa_client.yml"
+ - import_tasks: "{{ tasks_path }}/motd.yml"
handlers:
- - import_tasks: "{{ handlers_path }}/restart_services.yml"
+ - import_tasks: "{{ handlers_path }}/restart_services.yml"
Show replies by date