apt-repositories: extract sections
This commit is contained in:
parent
4a4d59003f
commit
b9a4fdf79a
|
@ -1 +1,2 @@
|
||||||
apt_repositories_components: "main"
|
apt_repositories_components: "main"
|
||||||
|
apt_repositories_backports: True
|
||||||
|
|
43
apt-repositories/tasks/backports.yml
Normal file
43
apt-repositories/tasks/backports.yml
Normal file
|
@ -0,0 +1,43 @@
|
||||||
|
---
|
||||||
|
|
||||||
|
- name: Backports sources list is installed
|
||||||
|
template:
|
||||||
|
src: jessie_backports.list.j2
|
||||||
|
dest: /etc/apt/sources.list.d/backports.list
|
||||||
|
force: yes
|
||||||
|
backup: yes
|
||||||
|
mode: "640"
|
||||||
|
notify: apt update
|
||||||
|
when: ansible_distribution_major_version == '8'
|
||||||
|
|
||||||
|
- name: Backports sources list is installed
|
||||||
|
template:
|
||||||
|
src: stretch_backports.list.j2
|
||||||
|
dest: /etc/apt/sources.list.d/backports.list
|
||||||
|
force: yes
|
||||||
|
backup: yes
|
||||||
|
mode: "640"
|
||||||
|
notify: apt update
|
||||||
|
when: ansible_distribution_major_version == '9'
|
||||||
|
|
||||||
|
- name: Backports configuration
|
||||||
|
copy:
|
||||||
|
src: jessie_backports_preferences
|
||||||
|
dest: /etc/apt/preferences.d/backports
|
||||||
|
force: yes
|
||||||
|
backup: yes
|
||||||
|
mode: "640"
|
||||||
|
notify: apt update
|
||||||
|
when: ansible_distribution_major_version == '8'
|
||||||
|
|
||||||
|
- name: Backports configuration
|
||||||
|
copy:
|
||||||
|
src: stretch_backports_preferences
|
||||||
|
dest: /etc/apt/preferences.d/backports
|
||||||
|
force: yes
|
||||||
|
backup: yes
|
||||||
|
mode: "640"
|
||||||
|
notify: apt update
|
||||||
|
when: ansible_distribution_major_version == '9'
|
||||||
|
|
||||||
|
- meta: flush_handlers
|
|
@ -1,43 +1,5 @@
|
||||||
---
|
---
|
||||||
|
|
||||||
- name: Backports sources list is installed
|
- name: Install APT Backports
|
||||||
template:
|
include: backports.yml
|
||||||
src: jessie_backports.list.j2
|
when: apt_repositories_backports
|
||||||
dest: /etc/apt/sources.list.d/backports.list
|
|
||||||
force: yes
|
|
||||||
backup: yes
|
|
||||||
mode: "640"
|
|
||||||
notify: apt update
|
|
||||||
when: ansible_distribution_major_version == '8'
|
|
||||||
|
|
||||||
- name: Backports sources list is installed
|
|
||||||
template:
|
|
||||||
src: stretch_backports.list.j2
|
|
||||||
dest: /etc/apt/sources.list.d/backports.list
|
|
||||||
force: yes
|
|
||||||
backup: yes
|
|
||||||
mode: "640"
|
|
||||||
notify: apt update
|
|
||||||
when: ansible_distribution_major_version == '9'
|
|
||||||
|
|
||||||
- name: Backports configuration
|
|
||||||
copy:
|
|
||||||
src: jessie_backports_preferences
|
|
||||||
dest: /etc/apt/preferences.d/backports
|
|
||||||
force: yes
|
|
||||||
backup: yes
|
|
||||||
mode: "640"
|
|
||||||
notify: apt update
|
|
||||||
when: ansible_distribution_major_version == '8'
|
|
||||||
|
|
||||||
- name: Backports configuration
|
|
||||||
copy:
|
|
||||||
src: stretch_backports_preferences
|
|
||||||
dest: /etc/apt/preferences.d/backports
|
|
||||||
force: yes
|
|
||||||
backup: yes
|
|
||||||
mode: "640"
|
|
||||||
notify: apt update
|
|
||||||
when: ansible_distribution_major_version == '9'
|
|
||||||
|
|
||||||
- meta: flush_handlers
|
|
||||||
|
|
Loading…
Reference in a new issue