generated from sebclem/ansible-role-template
49 lines
1.1 KiB
YAML
49 lines
1.1 KiB
YAML
|
---
|
||
|
- name: install dependencies
|
||
|
become: yes
|
||
|
package:
|
||
|
name:
|
||
|
- git
|
||
|
- zsh
|
||
|
- tar
|
||
|
- gzip
|
||
|
state: present
|
||
|
|
||
|
- name: create download directory
|
||
|
file:
|
||
|
path: "{{ antidote_download_dir }}"
|
||
|
state: directory
|
||
|
mode: "u=rwx,go=rx"
|
||
|
|
||
|
- name: download Antidote
|
||
|
get_url:
|
||
|
url: "{{ antidote_mirror }}/{{ antidote_filename }}"
|
||
|
dest: "{{ antidote_download_dir }}/{{ antidote_local_filename }}"
|
||
|
mode: "u=rw,go=r"
|
||
|
|
||
|
- name: create install directory
|
||
|
become: yes
|
||
|
become_user: "{{ username }}"
|
||
|
file:
|
||
|
path: "~{{ username }}/.antidote"
|
||
|
state: directory
|
||
|
mode: "u=rwx,go=rx"
|
||
|
loop: "{{ users | map(attribute='username') | list }}"
|
||
|
loop_control:
|
||
|
loop_var: username
|
||
|
|
||
|
- name: install Antidote
|
||
|
become: yes
|
||
|
unarchive:
|
||
|
src: "{{ antidote_download_dir }}/{{ antidote_local_filename }}"
|
||
|
remote_src: yes
|
||
|
dest: "~{{ username }}/.antidote"
|
||
|
extra_opts:
|
||
|
- "--strip-components=1"
|
||
|
creates: "~{{ username }}/.antidote/antidote.zsh"
|
||
|
owner: "{{ username }}"
|
||
|
mode: "go-w"
|
||
|
loop: "{{ users | map(attribute='username') | list }}"
|
||
|
loop_control:
|
||
|
loop_var: username
|