From 9ff21223a7731496f5da8744fb9bd239c9262555 Mon Sep 17 00:00:00 2001 From: Michele Cereda Date: Sun, 9 Oct 2022 14:48:51 +0200 Subject: [PATCH] Added ansible playbook to install Packman on opensuse --- ansible/zypper.add-repository.packman.yml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 ansible/zypper.add-repository.packman.yml diff --git a/ansible/zypper.add-repository.packman.yml b/ansible/zypper.add-repository.packman.yml new file mode 100644 index 0000000..b765c2f --- /dev/null +++ b/ansible/zypper.add-repository.packman.yml @@ -0,0 +1,22 @@ +--- + +- name: + tags: + - opensuse + - packman + - repository + - suse + - zypper + hosts: all + vars: + ansible_distribution_with_underscores: "{{ ansible_distribution | replace(' ', '_') }}" + repo_part_distribution: "{{ [ansible_distribution_with_underscores, ansible_distribution_version]|join('_') if ansible_distribution is search('leap', ignorecase=true) else ansible_distribution_with_underscores }}" + tasks: + - name: Add Packman to Zypper's repositories list + become: true + community.general.zypper_repository: + repo: "https://ftp.gwdg.de/pub/linux/misc/packman/suse/{{ repo_part_distribution }}/" + name: packman + priority: 90 + overwrite_multiple: true + auto_import_keys: true