mirror of
				https://git.lapiole.org/dani/ansible-roles.git
				synced 2025-10-31 02:41:36 +01:00 
			
		
		
		
	Update to 2022-08-03 01:00
This commit is contained in:
		| @@ -1,7 +1,7 @@ | ||||
| --- | ||||
|  | ||||
| - name: Create needed directories | ||||
|   file: path={{ nomad_root_dir }}/{{ item.dir }} state=directory owner={{ item.owner | default(omit) }} group={{ item.group | default(omit) }} mode={{ item.mode | default(omit) }} recurse={{ item.recurse | default(omit) }} | ||||
|   file: path={{ nomad_root_dir }}/{{ item.dir }} state=directory owner={{ item.owner | default(omit) }} group={{ item.group | default(omit) }} mode={{ item.mode | default(omit) }} | ||||
|   loop: | ||||
|     - dir: / | ||||
|       owner: root | ||||
| @@ -23,13 +23,9 @@ | ||||
|     - dir: tmp | ||||
|       owner: "{{ nomad_user }}" | ||||
|       group: "{{ nomad_user }}" | ||||
|       mode: u=rwX,g=-,o=- | ||||
|       recurse: True | ||||
|     - dir: data | ||||
|       owner: "{{ nomad_user }}" | ||||
|       group: "{{ nomad_user }}" | ||||
|       mode: u=rwX,g=-,o=- | ||||
|       recurse: True | ||||
|     - dir: etc | ||||
|       owner: root | ||||
|       group: "{{ nomad_user }}" | ||||
|   | ||||
| @@ -1,5 +1,14 @@ | ||||
| --- | ||||
|  | ||||
| # Load distribution specific variables | ||||
| - include_vars: "{{ item }}" | ||||
|   with_first_found: | ||||
|     - "{{ role_path }}/vars/{{ ansible_distribution }}-{{ ansible_distribution_major_version }}.yml" | ||||
|     - "{{ role_path }}/vars/{{ ansible_os_family }}-{{ ansible_distribution_major_version }}.yml" | ||||
|     - "{{ role_path }}/vars/{{ ansible_distribution }}.yml" | ||||
|     - "{{ role_path }}/vars/{{ ansible_os_family }}.yml" | ||||
|   tags: nomad | ||||
|  | ||||
| - set_fact: nomad_install_mode='none' | ||||
|   tags: nomad | ||||
|  | ||||
| @@ -23,3 +32,10 @@ | ||||
|  | ||||
| - when: nomad_bin.stat.exists and nomad_current_version != nomad_version | ||||
|   set_fact: nomad_install_mode='upgrade' | ||||
|  | ||||
| - debug: msg={{ nomad_conf.client.task_drivers | dict2items }} | ||||
|   tags: nomad | ||||
|  | ||||
| - name: Build a list of enabled task drivers | ||||
|   set_fact: nomad_enabled_task_drivers={{ nomad_conf.client.task_drivers | dict2items | selectattr('value.enabled', 'equalto', True) | map(attribute='key') }} | ||||
|   tags: nomad | ||||
|   | ||||
| @@ -8,6 +8,13 @@ | ||||
|       - unzip | ||||
|   tags: nomad | ||||
|  | ||||
| - name: Install task driver packages | ||||
|   package: name={{ nomad_task_driver_packages[item] }} | ||||
|   loop: "{{ nomad_enabled_task_drivers }}" | ||||
|   when: nomad_task_driver_packages[item] is defined and nomad_conf.client.enabled | ||||
|   notify: restart nomad | ||||
|   tags: nomad | ||||
|  | ||||
| - when: nomad_install_mode != 'none' | ||||
|   block: | ||||
|     - name: Download nomad | ||||
| @@ -59,3 +66,4 @@ | ||||
|     - pre | ||||
|     - post | ||||
|   tags: nomad | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Daniel Berteaud
					Daniel Berteaud