From 88418f0d241ab7555fc544bf4e6139b09e662254 Mon Sep 17 00:00:00 2001
From: Ramy Asselin <ramy.asselin@hp.com>
Date: Fri, 28 Aug 2015 13:25:52 -0700
Subject: [PATCH] Force gzip to run on log archives

Our log server filled up because log archive cron job was
not running due to a prompt in the gzip command. Use the
-f (force) option to force overwriting.

gzip: /srv/static/logs/58/213458/5/check/...file.txt.gz already exists; do you wish to overwrite (y or n)?

Change-Id: I47aca9603fa5c22a2726cee117f93d84252c314e
---
 modules/openstack_project/files/log_archive_maintenance.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/openstack_project/files/log_archive_maintenance.sh b/modules/openstack_project/files/log_archive_maintenance.sh
index 71af22a616..db09356677 100644
--- a/modules/openstack_project/files/log_archive_maintenance.sh
+++ b/modules/openstack_project/files/log_archive_maintenance.sh
@@ -5,7 +5,7 @@ find -O3 /srv/static/logs/ -depth -not -name robots.txt -not -name lost+found \
         -not -wholename /srv/static/logs/help/\* \( \
     \( -type f -mmin +10 -not -name \*\[.-\]gz -not -name \*\[._-\]\[zZ\] \
         \( -name \*.txt -or -name \*.html -or -name tmp\* \) \
-        -exec gzip \{\} \; \) \
+        -exec gzip -f \{\} \; \) \
     -o \( -type f -mtime +120 -execdir rm \{\} \; \) \
     -o \( -type d -empty -mtime +1 -execdir rmdir {} \; \) \)
 find -O3 /srv/static/docs-draft/ -depth -not -name lost+found \( \