Files
dotfiles/config/ansible/tasks/workstations/firefoxpwa.yml
Menno van Leeuwen 112d3679da
Some checks failed
Ansible Lint Check / check-ansible (push) Failing after 1m34s
Nix Format Check / check-format (push) Successful in 57s
style: add YAML document start markers to Ansible playbooks and tasks
2025-03-12 14:05:42 +01:00

52 lines
1.4 KiB
YAML

---
- 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