|
|
@ -28,9 +28,22 @@
|
|
|
|
args:
|
|
|
|
args:
|
|
|
|
chdir: "{{ repodir }}"
|
|
|
|
chdir: "{{ repodir }}"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Can't use apt_repository as it doesn't expose a trusted=yes option
|
|
|
|
- name: Install the repo
|
|
|
|
- name: Install the repo
|
|
|
|
apt_repository:
|
|
|
|
copy:
|
|
|
|
repo: "deb file:{{ repodir }} ./"
|
|
|
|
content: deb [trusted=yes] file:{{ repodir }} ./
|
|
|
|
validate_certs: no
|
|
|
|
dest: /etc/apt/sources.list.d/file_tmp_repo.list
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Need to uncomment the deb-src for the universe component for build-dep state
|
|
|
|
|
|
|
|
- name: Ensure deb-src for the universe component
|
|
|
|
|
|
|
|
lineinfile:
|
|
|
|
|
|
|
|
path: /etc/apt/sources.list
|
|
|
|
|
|
|
|
backrefs: True
|
|
|
|
|
|
|
|
regexp: ^#\s*deb-src http://archive\.ubuntu\.com/ubuntu/ (\w*){{ item }} universe$
|
|
|
|
|
|
|
|
line: deb-src http://archive.ubuntu.com/ubuntu \1{{ item }} universe
|
|
|
|
|
|
|
|
state: present
|
|
|
|
|
|
|
|
with_items:
|
|
|
|
|
|
|
|
- ''
|
|
|
|
|
|
|
|
- -updates
|
|
|
|
|
|
|
|
|
|
|
|
when: ansible_distribution in ['Ubuntu', 'Debian']
|
|
|
|
when: ansible_distribution in ['Ubuntu', 'Debian']
|
|
|
|