From 7b84a6c47fef05120cd49bf8b0882ce0c6bc2413 Mon Sep 17 00:00:00 2001 From: Scott Wallace Date: Sun, 20 Jan 2019 11:30:24 +0000 Subject: [PATCH] Added a way to install platform specific packages in Linux --- .ansible/roles/linux_desktop/tasks/software.yaml | 10 ++++++++++ .ansible/roles/linux_desktop/vars/main.yaml | 5 +++++ 2 files changed, 15 insertions(+) diff --git a/.ansible/roles/linux_desktop/tasks/software.yaml b/.ansible/roles/linux_desktop/tasks/software.yaml index 1524e1e..97ba35f 100644 --- a/.ansible/roles/linux_desktop/tasks/software.yaml +++ b/.ansible/roles/linux_desktop/tasks/software.yaml @@ -64,3 +64,13 @@ - name: Refresh font cache command: 'fc-cache -f' when: fontfile.stat.exists == false + +- name: Platform specific packages + tags: + - install + - platform + package: + name: "{{ item }}" + state: present + loop: "{{ lookup('vars', lookup('vars', 'ansible_system_vendor') + '_' + lookup('vars', 'ansible_form_factor') + '_packages') }}" + become: true diff --git a/.ansible/roles/linux_desktop/vars/main.yaml b/.ansible/roles/linux_desktop/vars/main.yaml index edd7a8b..891842f 100644 --- a/.ansible/roles/linux_desktop/vars/main.yaml +++ b/.ansible/roles/linux_desktop/vars/main.yaml @@ -48,3 +48,8 @@ gnome_extension_ids: - 28 # gtile - 1386 # notification counter - 19 # user themes + +# Platform specific packages +# Format: systemvendor_formfactor_packages +"Apple Inc._Laptop_packages": + - mbpfan