This commit is contained in:
parent
2231db18d5
commit
1f89e315a0
@ -7,4 +7,7 @@
|
|||||||
- hosts: all
|
- hosts: all
|
||||||
roles:
|
roles:
|
||||||
- testrole
|
- testrole
|
||||||
|
- hosts: docker2.t-juice.club
|
||||||
|
roles:
|
||||||
|
- vault
|
||||||
|
|
4
project/roles/vault/handlers/main.yml
Normal file
4
project/roles/vault/handlers/main.yml
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
---
|
||||||
|
- name: reload systemd
|
||||||
|
ansible.builtin.systemd:
|
||||||
|
daemon_reload: yes
|
17
project/roles/vault/tasks/main.yml
Normal file
17
project/roles/vault/tasks/main.yml
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
---
|
||||||
|
- name: Create service file
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: vault.service.j2
|
||||||
|
dest: /etc/systemd/system/vault.service
|
||||||
|
notify:
|
||||||
|
- reload systemd
|
||||||
|
|
||||||
|
- name: Ensure service is started
|
||||||
|
ansible.builtin.systemd:
|
||||||
|
state: started
|
||||||
|
name: vault
|
||||||
|
|
||||||
|
- name: Ensure service is enabled
|
||||||
|
ansible.builtin.systemd:
|
||||||
|
enabled: yes
|
||||||
|
name: vault
|
0
project/roles/vault/templates/vault.service.j2
Normal file
0
project/roles/vault/templates/vault.service.j2
Normal file
Loading…
Reference in New Issue
Block a user