-
Notifications
You must be signed in to change notification settings - Fork 2
/
macascode.yml
70 lines (58 loc) · 2.34 KB
/
macascode.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
---
- hosts: localhost
connection: local
vars_files:
- "{{ manuscript | default('./manuscripts/default-mac.yml')}}"
tasks:
- name: File manipulations
file:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'file') | list }}"
- name: Git repos
git:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'git') | list }}"
- name: Setup brew taps
homebrew_tap:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'homebrew_tap') | list }}"
- name: Install kegs with brew
homebrew:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'homebrew') | list }}"
- name: Install casks with brew-cask
homebrew_cask:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'homebrew_cask') | list }}"
- name: Install Ruby gems
gem:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'gem') | list }}"
- name: Shell executions
shell: "{{ item.shell }}"
args:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'shell') | list }}"
- name: Command executions
command: "{{ item.command }}"
args:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'command') | list }}"
- name: Configure git
git_config:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'git_config') | list }}"
- name: Configuration file manipulations
lineinfile:
"{{ item.parameters }}"
become: "{{ item.become | default('false')}}"
with_items: "{{ installs | selectattr('module', 'equalto', 'lineinfile') | list }}"