From e598588c32c986499000cce06b8a9b62a8ac47f5 Mon Sep 17 00:00:00 2001 From: Michal Arbet Date: Thu, 7 Oct 2021 16:44:21 +0200 Subject: [PATCH] Add way to change logrotate scheduling This patch adding way to change schedule for logrotate. Depends-On: https://review.opendev.org/c/openstack/kolla/+/813008 Change-Id: I033c51704bfb806f6515db26b8159fae12469ba5 --- ansible/roles/common/defaults/main.yml | 2 ++ releasenotes/notes/logrotate-schedule-4d24626629311e6c.yaml | 6 ++++++ 2 files changed, 8 insertions(+) create mode 100644 releasenotes/notes/logrotate-schedule-4d24626629311e6c.yaml diff --git a/ansible/roles/common/defaults/main.yml b/ansible/roles/common/defaults/main.yml index b68c8be3b4..174ac62bff 100644 --- a/ansible/roles/common/defaults/main.yml +++ b/ansible/roles/common/defaults/main.yml @@ -30,6 +30,7 @@ common_services: image: "{{ cron_image_full }}" environment: DUMMY_ENVIRONMENT: kolla_useless_env + KOLLA_LOGROTATE_SCHEDULE: "{{ cron_logrotate_schedule }}" volumes: "{{ cron_default_volumes + cron_extra_volumes }}" dimensions: "{{ cron_dimensions }}" @@ -97,6 +98,7 @@ fluentd_extra_volumes: "{{ default_extra_volumes }}" cron_logrotate_rotation_interval: "weekly" cron_logrotate_rotation_count: 6 +cron_logrotate_schedule: "daily" #################### # Fluentd diff --git a/releasenotes/notes/logrotate-schedule-4d24626629311e6c.yaml b/releasenotes/notes/logrotate-schedule-4d24626629311e6c.yaml new file mode 100644 index 0000000000..9791569f52 --- /dev/null +++ b/releasenotes/notes/logrotate-schedule-4d24626629311e6c.yaml @@ -0,0 +1,6 @@ +--- +features: + - | + Adds a new variable to be used by the common role, + ``cron_logrotate_schedule``. This allows to configure + how often the cron runs for logrotate.