Update all packages before installing new ones
Every now and again, a host will be in an initial state that prevents installing new packages due to existing packages having some script or obsoletes problem. Avoid this by first updating all packages, then installing new ones. Signed-off-by: Chris Evich <cevich@redhat.com>
This commit is contained in:
parent
b92b09ace3
commit
85e1b325e4
1 changed files with 7 additions and 7 deletions
|
@ -1,5 +1,12 @@
|
||||||
---
|
---
|
||||||
|
|
||||||
|
- name: Update all packages
|
||||||
|
package:
|
||||||
|
name: '*'
|
||||||
|
state: latest
|
||||||
|
async: 600
|
||||||
|
poll: 10
|
||||||
|
|
||||||
- name: Make sure we have all required packages
|
- name: Make sure we have all required packages
|
||||||
package:
|
package:
|
||||||
name: "{{ item }}"
|
name: "{{ item }}"
|
||||||
|
@ -65,13 +72,6 @@
|
||||||
- btrfs-progs-devel
|
- btrfs-progs-devel
|
||||||
when: ansible_distribution in ['Fedora']
|
when: ansible_distribution in ['Fedora']
|
||||||
|
|
||||||
- name: Update all packages
|
|
||||||
package:
|
|
||||||
name: '*'
|
|
||||||
state: latest
|
|
||||||
async: 600
|
|
||||||
poll: 10
|
|
||||||
|
|
||||||
- name: Setup swap to prevent kernel firing off the OOM killer
|
- name: Setup swap to prevent kernel firing off the OOM killer
|
||||||
shell: |
|
shell: |
|
||||||
truncate -s 8G /root/swap && \
|
truncate -s 8G /root/swap && \
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue