docker housekeeping: add buildx #180

Merged
mg merged 6 commits from dd into master 2024-09-16 16:42:47 +02:00
2 changed files with 4 additions and 3 deletions

View file

@ -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

View file

@ -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