summaryrefslogtreecommitdiff
path: root/puppet/modules/site_config
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2015-04-17 10:24:37 -0700
committerelijah <elijah@riseup.net>2015-04-17 10:24:37 -0700
commitf3aa928a91e0172a7a3c940940ab864194cb85a7 (patch)
tree433c2784c878301dcc36478e32496b9140d4a407 /puppet/modules/site_config
parent8bd7eca1913a8ca23e8b2c92b83aeac5a665131b (diff)
parent64cc83793aa35b84b60dd40305c7edf8369a187b (diff)
Merge branch 'bugfix/logs' into develop
Diffstat (limited to 'puppet/modules/site_config')
-rw-r--r--puppet/modules/site_config/manifests/default.pp1
-rw-r--r--puppet/modules/site_config/manifests/remove_files.pp36
2 files changed, 37 insertions, 0 deletions
diff --git a/puppet/modules/site_config/manifests/default.pp b/puppet/modules/site_config/manifests/default.pp
index c15080f5..e69e4b7b 100644
--- a/puppet/modules/site_config/manifests/default.pp
+++ b/puppet/modules/site_config/manifests/default.pp
@@ -58,6 +58,7 @@ class site_config::default {
# set up core leap files and directories
include site_config::files
+ include site_config::remove_files
if ! member($services, 'mx') {
include site_postfix::satellite
diff --git a/puppet/modules/site_config/manifests/remove_files.pp b/puppet/modules/site_config/manifests/remove_files.pp
new file mode 100644
index 00000000..44e3e47b
--- /dev/null
+++ b/puppet/modules/site_config/manifests/remove_files.pp
@@ -0,0 +1,36 @@
+#
+# Sometimes when we upgrade the platform, we need to ensure that files that
+# the platform previously created will get removed.
+#
+# These file removals don't need to be kept forever: we only need to remove
+# files that are present in the prior platform release.
+#
+# We can assume that the every node is upgraded from the previous platform
+# release.
+#
+
+class site_config::remove_files {
+
+ #
+ # Platform 0.7 removals
+ #
+
+ tidy {
+ '/etc/rsyslog.d/99-tapicero.conf':;
+ '/etc/rsyslog.d/99-leap-mx.conf':;
+ '/etc/rsyslog.d/01-webapp.conf':;
+ '/etc/rsyslog.d/50-stunnel.conf':;
+ '/etc/logrotate.d/mx':;
+ '/etc/logrotate.d/stunnel':;
+ '/var/log/stunnel4/stunnel.log':;
+ 'leap_mx':
+ path => '/var/log/',
+ recurse => true,
+ matches => 'leap_mx*';
+ '/srv/leap/webapp/public/provider.json':;
+ '/srv/leap/couchdb/designs/tmp_users':
+ recurse => true,
+ rmdirs => true;
+ }
+
+}