Refs #8025: Role debian-base. Change vn_no_witness for vn_fisrt_time

This commit is contained in:
Xavi Lleó 2024-10-17 16:38:52 +02:00
parent 513d7d4378
commit 5e6b7ab7ba
4 changed files with 5 additions and 5 deletions

View File

@ -1,4 +1,4 @@
vn_no_witness: false
vn_first_time: false
default_user: user
fail2ban:
email: "{{ sysadmin_mail }}"

View File

@ -1,5 +1,5 @@
- name: Generate root password
when: vn_no_witness
when: vn_first_time
block:
- name: Search root password into Passbolt
set_fact:

View File

@ -3,7 +3,7 @@
path: "/etc/ssh/ssh_host_{{ item.type }}_key"
type: "{{ item.type }}"
force: yes
when: vn_no_witness
when: vn_first_time
loop:
- { type: 'rsa' }
- { type: 'ecdsa' }

View File

@ -4,9 +4,9 @@
register: keys_generated_marker
- name: Generate variable if not exists
set_fact:
vn_no_witness: "{{ not keys_generated_marker.stat.exists }}"
vn_first_time: "{{ not keys_generated_marker.stat.exists }}"
- name: Create marker file to indicate vn happends
file:
path: /etc/vn.witness
state: touch
when: vn_no_witness
when: vn_first_time