From 49a6a3f712731b3a84157c7d7da010bb046376c5 Mon Sep 17 00:00:00 2001 From: Florian RICHER Date: Sun, 21 May 2023 00:06:21 +0200 Subject: [PATCH] [CLEAN] Prune all docker --- playbook.yml | 2 ++ roles/clean/tasks/docker.yml | 10 ++++++++++ roles/clean/tasks/main.yml | 4 ++++ 3 files changed, 16 insertions(+) create mode 100644 roles/clean/tasks/docker.yml create mode 100644 roles/clean/tasks/main.yml diff --git a/playbook.yml b/playbook.yml index 5e1f8f6..edc3fba 100644 --- a/playbook.yml +++ b/playbook.yml @@ -11,3 +11,5 @@ - { role: home_assistant, tags: ["home_assistant"] } - { role: n8n, tags: ["n8n"] } - { role: matrix, tags: ["matrix"] } + - { role: iptables, tags: ["iptables"] } + - { role: clean, tags: ["clean"] } diff --git a/roles/clean/tasks/docker.yml b/roles/clean/tasks/docker.yml new file mode 100644 index 0000000..08c8975 --- /dev/null +++ b/roles/clean/tasks/docker.yml @@ -0,0 +1,10 @@ +--- + +- name: Prune everything + community.docker.docker_prune: + containers: true + images: true + networks: true + volumes: true + builder_cache: true + become: yes \ No newline at end of file diff --git a/roles/clean/tasks/main.yml b/roles/clean/tasks/main.yml new file mode 100644 index 0000000..56d9bb3 --- /dev/null +++ b/roles/clean/tasks/main.yml @@ -0,0 +1,4 @@ +--- + +- ansible.builtin.import_tasks: docker.yml + name: docker \ No newline at end of file