-
Notifications
You must be signed in to change notification settings - Fork 5
/
orchestrate.yml
48 lines (45 loc) · 1.44 KB
/
orchestrate.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
---
# Overview: configuring a developer machine in just minutes
- hosts: localhost
name: Hanzo Lookup
vars:
ansible_python_interpreter: /usr/bin/python3
ansible_remote_tmp: "{{ lookup('env', 'ANSIBLE_FOLDER') }}/tmp"
tags: always
tasks:
- name: Configure the environment
set_fact:
email: "{{ lookup('env', 'HANZO_EMAIL') | default(false, True) }}"
fullname: "{{ lookup('env', 'HANZO_FULLNAME') | default(false, True) }}"
username: "{{ lookup('env', 'HANZO_USERNAME') | default(false, True) }}"
- name: Checking required variables
fail:
msg: "Variable '{{item}}' is not defined."
when: not vars[item]
with_items:
- email
- fullname
- username
- hosts: localhost
name: Archlinux/toolbox
vars:
ansible_python_interpreter: /usr/bin/python3
ansible_remote_tmp: "{{ lookup('env', 'ANSIBLE_FOLDER') }}/tmp"
tags: always
become: yes
tasks:
- block:
- include_role: name=base
- include_role: name=aur
- include_role: name=system
- include_role: name=shell
- include_role: name=security
- include_role: name=development
- include_role: name=editors
- include_role: name=orchestrators
- include_role: name=provisioning
- include_role: name=cluster
- include_role: name=extras
- include_role: name=dotfiles
always:
- include_role: name=cleanup