We're now using the built-in deb822_repository module to handle Debian package repositories. We no longer need individual yml files per repo and instead perform just one loop call of the deb822_repository module. We also update repo content to Proxmox VE 9 and Debian 13.
19 lines
744 B
YAML
19 lines
744 B
YAML
# SPDX-License-Identifier: MIT
|
|
- name: 'Set correct repositories'
|
|
loop_control:
|
|
loop_var: 'repo'
|
|
index_var: 'i'
|
|
label: 'Make sure the ''{{ repo.name }}.source'' repo file is {% if repo.state == ''absent'' %}absent{% else %}present ({% if repo.enabled %}and enabled{% else %}but disabled{% endif %}){% endif %}, this has the {{ repo.description }}'
|
|
loop: '{{ deb822_repos }}'
|
|
ansible.builtin.deb822_repository:
|
|
name: '{{ repo.name }}'
|
|
enabled: '{{ repo.enabled }}'
|
|
state: '{{ repo.state | default(''present'') }}'
|
|
types: '{{ repo.types }}'
|
|
uris: '{{ repo.uris }}'
|
|
suites: '{{ repo.suites }}'
|
|
components: '{{ repo.components }}'
|
|
signed_by: '{{ repo.signed_by }}'
|
|
notify:
|
|
- 'apt-get update'
|