Test Repo für Ansible Semaphore
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
523 B

---
- name: Setup Watchtower Updater Script
hosts: all
become: true
tasks:
- name: Create watchtower updater script
ansible.builtin.copy:
dest: /usr/local/bin/docker-update
mode: '0755'
owner: root
group: root
content: |
#!/bin/bash
test -x "$(which docker)" || exit 1
docker run --rm \
-v /var/run/docker.sock:/var/run/docker.sock \
containrrr/watchtower \
--run-once
docker image prune -a