mg
4e83d8d887
Co-authored-by: Michael Grote <michael.grote@posteo.de> Reviewed-on: mg/ansible#225 Co-authored-by: mg <michael.grote@posteo.de> Co-committed-by: mg <michael.grote@posteo.de>
36 lines
1 KiB
YAML
36 lines
1 KiB
YAML
---
|
|
- name: ensure apt.conf exists
|
|
become: true
|
|
ansible.builtin.template:
|
|
src: apt.conf
|
|
dest: "{{ apt_proxy_apt_conf_path | default ('/etc/apt/apt.conf') }}"
|
|
backup: yes
|
|
notify: update package lists
|
|
|
|
- name: remove enterprise-Repository
|
|
become: yes
|
|
ansible.builtin.file:
|
|
path: "{{ manage_sources_enterprise_repo_path }}"
|
|
state: absent
|
|
|
|
- name: check if pve-no-subscription repo keys exists
|
|
stat:
|
|
path: "{{ manage_sources_apt_repo_key_path }}"
|
|
register: pve_no_subscription_repo_keys
|
|
|
|
- name: add pve-no-subscription repo keys
|
|
become: yes
|
|
ansible.builtin.apt_key:
|
|
url: "{{ manage_sources_apt_repo_key_url }}"
|
|
state: present
|
|
notify: update package lists
|
|
when: pve_no_subscription_repo_keys.stat.exists == false
|
|
|
|
- name: add pve-no-subscription repo
|
|
become: yes
|
|
ansible.builtin.apt_repository:
|
|
repo: "{{ manage_sources_apt_repo_no_subscription }}"
|
|
state: present
|
|
filename: pve-no-subscription
|
|
update_cache: no
|
|
notify: update package lists
|