From 3943c203e8ecd0cdd98af851709240d4af4a7823 Mon Sep 17 00:00:00 2001 From: Yoshida Shunsuke Date: Sat, 13 Feb 2021 07:38:02 +0000 Subject: [PATCH] auto debian package update by cron-apt --- pyconjp.yml | 1 + roles/cron-apt/tasks/main.yml | 15 +++++++++++++++ 2 files changed, 16 insertions(+) create mode 100755 roles/cron-apt/tasks/main.yml diff --git a/pyconjp.yml b/pyconjp.yml index 8472499..404eb32 100644 --- a/pyconjp.yml +++ b/pyconjp.yml @@ -19,3 +19,4 @@ - { tags: bot, role: pyconjpbot } - { tags: n, role: nginx } - { tags: infra, role: infra } + - { tags: cron-apt, role: cron-apt } diff --git a/roles/cron-apt/tasks/main.yml b/roles/cron-apt/tasks/main.yml new file mode 100755 index 0000000..11a626c --- /dev/null +++ b/roles/cron-apt/tasks/main.yml @@ -0,0 +1,15 @@ +--- +- name: install cron-apt + apt: + name: cron-apt + +- name: update configuration file + copy: + content: | + autoclean -y + #auto update + dist-upgrade -y -o APT::Get::Show-Upgraded=true + dest: /etc/cron-apt/action.d/3-download + owner: root + group: root + mode: 0644