From 3a944a62d0c1e3898bde00427e6f995b86afbdd4 Mon Sep 17 00:00:00 2001 From: Alex Stuart Date: Tue, 7 Sep 2021 08:14:11 +0100 Subject: [PATCH] Delete logfiles on stats server to align with Test SP privacy policy See ukf/ukf-meta#320 for details --- utilities/stats-sync.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/utilities/stats-sync.sh b/utilities/stats-sync.sh index 147f17c1..e204fceb 100755 --- a/utilities/stats-sync.sh +++ b/utilities/stats-sync.sh @@ -33,9 +33,12 @@ rsync -at --exclude modsec* stats@test-idp:/var/log/httpd/* $logslocation/test-i rsync -at stats@test-idp:/opt/shibboleth-idp/logs/idp-audit* $logslocation/test-idp/ # Logs from Test SP -rsync -at --exclude modsec* stats@test-sp:/var/log/httpd/* $logslocation/test-sp/ -rsync -at stats@test-sp:/var/log/shibboleth/shibd* $logslocation/test-sp/ -rsync -at stats@test-sp:/var/log/shibboleth/transaction* $logslocation/test-sp/ +# +# The Test SP has a cronjob to remove logs with PII > 30 days old, --delete keeps repo in sync +# +rsync --delete -at --exclude modsec* stats@test-sp:/var/log/httpd/* $logslocation/test-sp/ +rsync --delete -at stats@test-sp:/var/log/shibboleth/shibd* $logslocation/test-sp/ +rsync --delete -at stats@test-sp:/var/log/shibboleth/transaction* $logslocation/test-sp/ # Exit happily exit 0