mac-dev-playbook/main.yml
Paul van Noort 01c1e0d2a1 dingen
2021-04-07 13:26:28 +02:00

52 lines
1.3 KiB
YAML

---
- 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: geerlingguy.homebrew
tags: ['homebrew']
- role: geerlingguy.dotfiles
when: configure_dotfiles
tags: ['dotfiles']
- role: geerlingguy.mas
when: mas_installed_apps
tags: ['mas']
tasks:
- include_tasks: tasks/ansible-setup.yml
- include_tasks: tasks/sudoers.yml
when: configure_sudoers
- include_tasks: tasks/terminal.yml
when: configure_terminal
- include_tasks: tasks/osx.yml
when: configure_osx
tags: ['osx']
- include_tasks: tasks/extra-packages.yml
tags: ['extra-packages']
- name: Install global Ruby gems.
gem:
name: "{{ item.name | default(item) }}"
state: "{{ item.state | default('present') }}"
version: "{{ item.version | default(omit) }}"
user_install: false
executable: "{{ item.executable | default(omit) }}"
loop: "{{ gem_packages }}"
- 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) }}"