On Fri, 2022-07-22 at 20:04 +0200, Johannes Kastl wrote:
On 22.07.22 at 19:57 Scott Bradnick wrote:
I am at a point though where I should look into something to manage zypper repos ~ at worst as a learning experience for how ansible will be packaged going forward 😉️
Instead of using the ansible package with its many collections you can of course only install the zypper_repository module from the community.general collection:
https://docs.ansible.com/ansible/latest/collections/community/general/zypper...
This module is part of the community.general collection (version 5.3.0). You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list. To install it, use: ansible-galaxy collection install community.general. To use it in a playbook, specify: community.general.zypper_repository.
Johannes
-- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de
B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
Very cool, thanks for the info. Got a good starting point going now: ``` $ ansible-galaxy collection list # /home/scott/.ansible/collections/ansible_collections Collection Version ----------------- ------- community.general 5.3.0 ``` ``` $ cat repos.yml #!/usr/bin/env ansible-playbook --- - hosts: all tasks: - name: Add OBS home:sbradnick repository community.general.zypper_repository: repo: 'https://download.opensuse.org/repositories/home:/sbradnick/openSUSE_Tumblewe...' priority: 91 become: true when: ansible_distribution == "openSUSE Tumbleweed" ``` -- ~ Scott Bradnick |- Windows Subsystem for Linux (WSL) Developer |-- Tumbleweed: |--- Dell Precision 5540 [NVIDIA Quadro T1000] (x86_64) |--- O-DROID H2+ [UHD Graphics 600] (x86_64) |--- 2x Raspberry Pi 4 Model B Rev 1.2 (aarch64) |--- 1x Raspberry Pi 3 Model B Rev 1.2 (aarch64) |--- WinBook TW100 (x86_64) https://keys.openpgp.org/ :: DBC5AA9A2D2BAEBC