30 lines
821 B
YAML
30 lines
821 B
YAML
---
|
|
# task/prerequisites file for hashicorp_nomad
|
|
- name: "Create group {{ hashi_nomad_group }}"
|
|
ansible.builtin.group:
|
|
name: "{{ hashi_nomad_user }}"
|
|
state: present
|
|
|
|
- name: "Create user {{ hashi_nomad_user }}"
|
|
ansible.builtin.user:
|
|
name: "{{ hashi_nomad_user }}"
|
|
group: "{{ hashi_nomad_group }}"
|
|
shell: /bin/false
|
|
state: present
|
|
|
|
- name: "Create directory {{ hashi_nomad_config_dir }}"
|
|
ansible.builtin.file:
|
|
path: "{{ hashi_nomad_config_dir }}"
|
|
state: directory
|
|
owner: "{{ hashi_nomad_user }}"
|
|
group: "{{ hashi_nomad_group }}"
|
|
mode: '0755'
|
|
|
|
- name: "Create directory {{ hashi_nomad_data_dir }}"
|
|
ansible.builtin.file:
|
|
path: "{{ hashi_nomad_data_dir }}"
|
|
state: directory
|
|
owner: "{{ hashi_nomad_user }}"
|
|
group: "{{ hashi_nomad_group }}"
|
|
mode: '0755'
|