Re-format the layout of the Ansible configuration

This commit is contained in:
Scott Wallace 2019-02-22 15:18:21 +00:00
parent 770490e7e3
commit 40eab0d3f2
12 changed files with 16 additions and 7 deletions

View file

@ -3,5 +3,19 @@
roles:
- role: desktop
vars_files:
- "roles/desktop/vars/{{ ansible_system|lower }}.yaml"
- "roles/desktop/vars/common.yaml"
- roles/desktop/vars/common.yaml
- "roles/desktop/vars/{{ ansible_system | lower }}.yaml"
tasks:
- import_tasks: roles/desktop/tasks/common/firefox.yaml
- import_tasks: roles/desktop/tasks/common/screen.yaml
- block:
- import_tasks: roles/desktop/tasks/darwin/homebrew.yaml
- import_tasks: roles/desktop/tasks/darwin/mas.yaml
- import_tasks: roles/desktop/tasks/darwin/prefs.yaml
when: ansible_system == 'Darwin'
- block:
- import_tasks: roles/desktop/tasks/linux/software.yaml
- import_tasks: roles/desktop/tasks/linux/config.yaml
when: ansible_system == 'Linux'

View file

@ -1,5 +0,0 @@
- name: "Desktop tasks ({{ ansible_system }})"
include: "{{ loop_task }}"
loop: "{{ query('fileglob', \"{{ ansible_system|lower }}/*\", \"common/*\") | sort }}"
loop_control:
loop_var: loop_task