Enable extrepo
This commit is contained in:
parent
2f6db27a38
commit
78f558feaf
2 changed files with 12 additions and 10 deletions
|
|
@ -19,16 +19,12 @@
|
||||||
|
|
||||||
- name: Activate contrib and non-free repos for extrepo
|
- name: Activate contrib and non-free repos for extrepo
|
||||||
ansible.builtin.lineinfile:
|
ansible.builtin.lineinfile:
|
||||||
dest: /etc/extrepo/config.yaml
|
path: /etc/extrepo/config.yaml
|
||||||
regexp: '^#\s*-\s*(contrib|non-free)'
|
regexp: '^# - {{ item }}'
|
||||||
line: '- \1'
|
line: '- {{ item }}'
|
||||||
backrefs: true
|
with_items:
|
||||||
|
- contrib
|
||||||
- name: Enable extrepo
|
- non-free
|
||||||
ansible.builtin.command:
|
|
||||||
cmd: extrepo enable
|
|
||||||
register: extrepo_enable
|
|
||||||
changed_when: "'enabled' in extrepo_enable.stdout"
|
|
||||||
|
|
||||||
- name: Allow sudo without password for user
|
- name: Allow sudo without password for user
|
||||||
ansible.builtin.lineinfile:
|
ansible.builtin.lineinfile:
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,12 @@
|
||||||
register: extrepo_update
|
register: extrepo_update
|
||||||
changed_when: "'No updates' not in extrepo_update.stdout"
|
changed_when: "'No updates' not in extrepo_update.stdout"
|
||||||
|
|
||||||
|
- name: Enable VirtualBox repository using extrepo
|
||||||
|
ansible.builtin.command:
|
||||||
|
cmd: extrepo enable virtualbox
|
||||||
|
register: extrepo_enable
|
||||||
|
changed_when: "'enabled' in extrepo_enable.stdout"
|
||||||
|
|
||||||
- name: Update package cache
|
- name: Update package cache
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
update_cache: true
|
update_cache: true
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue