From f77d57eba84c44175bba721f9a8451cf673ebef5 Mon Sep 17 00:00:00 2001 From: Felix Stupp Date: Fri, 9 Aug 2019 15:49:45 +0200 Subject: [PATCH] server/gitea: Added auto backup support for repositories --- roles/server/gitea/tasks/main.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/roles/server/gitea/tasks/main.yml b/roles/server/gitea/tasks/main.yml index d7be82b..c26630f 100644 --- a/roles/server/gitea/tasks/main.yml +++ b/roles/server/gitea/tasks/main.yml @@ -80,6 +80,15 @@ - reload systemd - restart gitea +- name: Configure auto backup of gitea repositories directory + cron: + hour: 1 + minute: 0 + job: "{{ global_helper_directory }}/backup_files.sh {{ gitea_repositories_directory | quote }} {{ domain | quote }}" + name: "backup gitea repositories of {{ domain }}" + state: present + +# TODO Disable backup in update process - name: Enable auto update of gitea cron: hour: 2