Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: modules/statsmaster/manifests/downloads.pp

Issue 6293281981857792: Issue 239 - Move AWStats processing to the stats server (Closed)
Patch Set: Created April 23, 2014, 1:14 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: modules/statsmaster/manifests/downloads.pp
===================================================================
new file mode 100644
--- /dev/null
+++ b/modules/statsmaster/manifests/downloads.pp
@@ -0,0 +1,40 @@
+class statsmaster::downloads {
+ package {['pypy', 'python-jinja2']:}
+
+ class {'sitescripts':
+ sitescriptsini_source => 'puppet:///modules/statsmaster/sitescripts.ini',
+ }
+
+ file {'/var/www/stats':
Felix Dahlke 2014/04/25 04:37:08 Could also be merged with the file resource below
+ ensure => directory,
+ mode => 0755,
+ owner => stats,
+ }
+
+ file {'/var/www/statsdata':
+ ensure => directory,
+ mode => 0755,
+ owner => stats,
+ }
+
+ file {'/var/www/statsdata/usercounts.html':
+ ensure => file,
+ mode => 0444,
+ source => 'puppet:///modules/statsmaster/usercounts.html',
+ owner => stats,
+ }
+
+ cron {'updatestats':
+ ensure => present,
+ require => [
+ Package['pypy'],
+ Package['python-jinja2'],
+ Exec["fetch_sitescripts"]
+ ],
+ command => "pypy -m sitescripts.stats.bin.logprocessor && python -m sitescripts.stats.bin.pagegenerator",
+ environment => ['MAILTO=admins@adblockplus.org,root', 'PYTHONPATH=/opt/sitescripts'],
Felix Dahlke 2014/04/25 04:37:08 Nit: Wrap at 80 columns? (Note that for the line a
+ user => stats,
+ hour => 1,
+ minute => 30,
+ }
+}

Powered by Google App Engine
This is Rietveld