mac-setup/main.yml
2024-07-26 17:25:48 +02:00

42 lines
1.0 KiB
YAML

---
- name: Configure host.
hosts: all
vars_files:
- default.config.yml
pre_tasks:
- name: Include playbook configuration.
include_vars: "{{ item }}"
with_fileglob:
- "{{ playbook_dir }}/config.yml"
tags: ['always']
roles:
- role: elliotweiser.osx-command-line-tools
- role: geerlingguy.mac.homebrew
tags: ['homebrew']
- role: geerlingguy.mac.mas
when: mas_installed_apps or mas_installed_app_ids
tags: ['mas']
- role: geerlingguy.mac.dock
when: configure_dock
tags: ['dock']
- role: dotfiles
tags: [ "dotfiles" ]
tasks:
- import_tasks: tasks/osx.yml
when: configure_osx
tags: ['osx']
- name: Run post-provision task files in a block.
tags: ['post']
block:
- name: Run configured post-provision ansible task files.
include_tasks: "{{ outer_item }}"
loop_control:
loop_var: outer_item
with_fileglob: "{{ post_provision_tasks | default(omit) }}"