roles/common: Use a fact for base packages on Debian
This is safer and ends up being faster because all packages get in- stalled in one apt transaction.
This commit is contained in:
parent
d46c64ca29
commit
10200e52ab
@ -4,9 +4,9 @@
|
|||||||
- name: Configure apt mirror
|
- name: Configure apt mirror
|
||||||
template: src=sources.list.j2 dest=/etc/apt/sources.list owner=root group=root mode=0644
|
template: src=sources.list.j2 dest=/etc/apt/sources.list owner=root group=root mode=0644
|
||||||
|
|
||||||
- name: Install base packages
|
- name: Set fact for base packages
|
||||||
apt: name={{ item }} update_cache=yes
|
set_fact:
|
||||||
loop:
|
base_packages:
|
||||||
- git
|
- git
|
||||||
- tmux
|
- tmux
|
||||||
- iotop
|
- iotop
|
||||||
@ -16,13 +16,16 @@
|
|||||||
- safe-rm
|
- safe-rm
|
||||||
- debian-goodies
|
- debian-goodies
|
||||||
- mosh
|
- mosh
|
||||||
- python-pycurl # for ansible's apt_repository
|
- python3-pycurl # for ansible's apt_repository
|
||||||
- lzop
|
- lzop
|
||||||
- vim
|
- vim
|
||||||
- lrzip
|
- lrzip
|
||||||
- unzip
|
- unzip
|
||||||
- apt-transport-https # for https support in apt
|
- apt-transport-https # for https support in apt
|
||||||
|
|
||||||
|
- name: Install base packages
|
||||||
|
apt: name={{ base_packages }} update_cache=yes
|
||||||
|
|
||||||
- name: Configure cron-apt
|
- name: Configure cron-apt
|
||||||
import_tasks: cron-apt.yml
|
import_tasks: cron-apt.yml
|
||||||
tags: cron-apt
|
tags: cron-apt
|
||||||
|
Loading…
Reference in New Issue
Block a user