copr-builders: assert 15G free space in /var/lib/copr-rpmbuild
This commit is contained in:
parent
7639b55d5a
commit
bda1d88854
2 changed files with 19 additions and 0 deletions
|
@ -0,0 +1,9 @@
|
|||
---
|
||||
- name: "call dnf on {{ path }}"
|
||||
shell: "df '{{ path }}' --output=avail | tail -1"
|
||||
register: df
|
||||
changed_when: false
|
||||
|
||||
- name: "assert {{ path }} has {{ size }} bytes left (has {{ df.stdout }})"
|
||||
assert:
|
||||
that: "df.stdout|int > size|int"
|
|
@ -246,3 +246,13 @@
|
|||
success_msg: "Builder has enough memory/swap!"
|
||||
when:
|
||||
- prepare_base_image is not defined
|
||||
|
||||
- name: check disk space
|
||||
include_tasks:
|
||||
file: check_path_free_space.yml
|
||||
vars:
|
||||
path: "{{ item.path }}"
|
||||
size: "{{ item.size|int }}"
|
||||
loop:
|
||||
- path: /var/lib/copr-rpmbuild
|
||||
size: 15000000
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue