Skip to content

Instantly share code, notes, and snippets.

@roib20
Created May 25, 2023 14:58
Show Gist options
  • Save roib20/3e6932db4a476fbd4bc28b86296642c9 to your computer and use it in GitHub Desktop.
Save roib20/3e6932db4a476fbd4bc28b86296642c9 to your computer and use it in GitHub Desktop.
Adding Mozilla PPA repository using the new `deb822_repository` Ansible module
---
- hosts: localhost
connection: local
gather_facts: true
tasks:
- name: Add PPA repositories
when: ansible_distribution == 'Ubuntu'
become: true
block:
- name: Add Mozilla PPA repository
ansible.builtin.deb822_repository:
name: mozillateam-ubuntu-ppa
state: present
types: [deb]
uris: "http://ppa.launchpad.net/mozillateam/ppa/ubuntu"
suites: ["{{ ansible_distribution_release|lower }}"]
components: [main]
signed_by: "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x0AB215679C571D1C8325275B9BDB3D89CE49EC21"
enabled: yes
@roib20
Copy link
Author

roib20 commented Apr 25, 2024

Since January 2024, Mozilla now offers an official repository for Debian-based distributions.

Although the PPA is still valid, I have personally changed over to this distribution on my machine. It is also a better option for Debian.

- name: Add Mozilla repository
  ansible.builtin.deb822_repository:
    name: mozilla
    state: present
    types: [deb]
    uris: "https://packages.mozilla.org/apt"
    suites: [mozilla]
    components: [main]
    signed_by: "https://packages.mozilla.org/apt/repo-signing-key.gpg"
    enabled: yes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment