docker housekeeping: add buildx (#180)
Reviewed-on: https://git.mgrote.net///mg/homeserver/pulls/180 Co-authored-by: Michael Grote <michael.grote@posteo.de> Co-committed-by: Michael Grote <michael.grote@posteo.de>
This commit is contained in:
parent
5cd43e8f3d
commit
0b277bf56a
2 changed files with 4 additions and 3 deletions
|
@ -24,10 +24,11 @@
|
|||
|
||||
- name: Enable Units
|
||||
become: true
|
||||
ansible.builtin.systemd:
|
||||
ansible.builtin.systemd_service:
|
||||
name: "{{ item }}"
|
||||
enabled: true
|
||||
masked: false
|
||||
daemon_reload: true
|
||||
with_items:
|
||||
- docker_housekeeping.service
|
||||
- docker_housekeeping.timer
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
{{ file_header | default () }}
|
||||
[Unit]
|
||||
Description=Docker housekeeping tasks
|
||||
Description=docker housekeeping tasks
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/usr/bin/docker system prune --force --filter "until=24h"
|
||||
ExecStart=/bin/bash -c '/usr/bin/docker system prune --force --filter "until=24h" --all && /usr/bin/docker buildx prune --force --filter "until=24h"'
|
||||
# https://docs.docker.com/config/pruning
|
||||
|
|
Loading…
Reference in a new issue