refactor: add Ansible tasks for Firefox PWA installation and integration
This commit is contained in:
51
config/ansible/tasks/workstations/firefoxpwa.yml
Normal file
51
config/ansible/tasks/workstations/firefoxpwa.yml
Normal file
@ -0,0 +1,51 @@
|
||||
---
|
||||
- name: Install required packages for FirefoxPWA
|
||||
ansible.builtin.apt:
|
||||
name:
|
||||
- curl
|
||||
- gpg
|
||||
- apt-transport-https
|
||||
- debian-archive-keyring
|
||||
state: present
|
||||
update_cache: true
|
||||
become: true
|
||||
|
||||
- name: Download FirefoxPWA GPG key
|
||||
ansible.builtin.get_url:
|
||||
url: https://packagecloud.io/filips/FirefoxPWA/gpgkey
|
||||
dest: /usr/share/keyrings/firefoxpwa-keyring.gpg
|
||||
mode: '0644'
|
||||
become: true
|
||||
|
||||
- name: Import FirefoxPWA GPG key
|
||||
ansible.builtin.command:
|
||||
cmd: "set -o pipefail && gpg --dearmor < /usr/share/keyrings/firefoxpwa-keyring.gpg | tee /usr/share/keyrings/firefoxpwa-keyring.gpg > /dev/null"
|
||||
args:
|
||||
creates: /usr/share/keyrings/firefoxpwa-keyring.gpg
|
||||
become: true
|
||||
|
||||
- name: Add FirefoxPWA repository
|
||||
ansible.builtin.copy:
|
||||
content: "deb [signed-by=/usr/share/keyrings/firefoxpwa-keyring.gpg] https://packagecloud.io/filips/FirefoxPWA/any any main"
|
||||
dest: /etc/apt/sources.list.d/firefoxpwa.list
|
||||
mode: '0644'
|
||||
become: true
|
||||
|
||||
- name: Update apt cache
|
||||
ansible.builtin.apt:
|
||||
update_cache: true
|
||||
become: true
|
||||
|
||||
- name: Install FirefoxPWA package
|
||||
ansible.builtin.apt:
|
||||
name: firefoxpwa
|
||||
state: present
|
||||
become: true
|
||||
|
||||
- name: Ensure FirefoxPWA integration is enabled for compatible browsers
|
||||
ansible.builtin.command:
|
||||
cmd: "firefoxpwa install --global"
|
||||
register: pwa_integration
|
||||
changed_when: "'Integration installed' in pwa_integration.stdout"
|
||||
failed_when: false
|
||||
become: true
|
@ -20,6 +20,9 @@
|
||||
- name: Include 1Password Zen Browser tasks
|
||||
ansible.builtin.import_tasks: tasks/workstations/1password-zen-browser.yml
|
||||
|
||||
- name: Include Firefox PWA tasks
|
||||
ansible.builtin.import_tasks: tasks/workstations/firefoxpwa.yml
|
||||
|
||||
- name: Include Ulauncher tasks
|
||||
ansible.builtin.import_tasks: tasks/workstations/ulauncher.yml
|
||||
|
||||
|
Reference in New Issue
Block a user