| OLD | NEW | 
|   1 class sitescripts ( |   1 class sitescripts ( | 
|   2     $sitescriptsini_source = '', |   2     $sitescriptsini_source = '', | 
|   3     $sitescriptsini_content = '', |   3     $sitescriptsini_content = '', | 
|   4   ){ |   4   ){ | 
|   5  |   5  | 
|   6   @concat {'/etc/sitescripts.ini': |   6   @concat {'/etc/sitescripts.ini': | 
|   7     mode => 644, |   7     mode => 644, | 
|   8     owner => root, |   8     owner => root, | 
|   9     group => root, |   9     group => root, | 
|  10   } |  10   } | 
| (...skipping 28 matching lines...) Expand all  Loading... | 
|  39   configfragment {'/etc/sitescripts.ini': |  39   configfragment {'/etc/sitescripts.ini': | 
|  40     content => $content, |  40     content => $content, | 
|  41     source => $source, |  41     source => $source, | 
|  42   } |  42   } | 
|  43  |  43  | 
|  44   $configfragments = hiera('sitescripts::configfragments', {}) |  44   $configfragments = hiera('sitescripts::configfragments', {}) | 
|  45   create_resources('sitescripts::configfragment', $configfragments) |  45   create_resources('sitescripts::configfragment', $configfragments) | 
|  46  |  46  | 
|  47   exec { "fetch_sitescripts": |  47   exec { "fetch_sitescripts": | 
|  48     command => "hg clone https://hg.adblockplus.org/sitescripts /opt/sitescripts
    ", |  48     command => "hg clone https://hg.adblockplus.org/sitescripts /opt/sitescripts
    ", | 
|  49     path => ["/usr/bin/", "/bin/"], |  49     path => ["/usr/local/bin", "/usr/bin/", "/bin/"], | 
|  50     require => Package['mercurial'], |  50     require => Package['mercurial'], | 
|  51     onlyif => "test ! -d /opt/sitescripts" |  51     onlyif => "test ! -d /opt/sitescripts" | 
|  52   } |  52   } | 
|  53  |  53  | 
|  54   cron {"update_sitescripts": |  54   cron {"update_sitescripts": | 
|  55     ensure => present, |  55     ensure => present, | 
|  56     command => "hg pull -q -u -R /opt/sitescripts && /opt/sitescripts/ensure_dep
    endencies.py -q", |  56     command => "hg pull -q -u -R /opt/sitescripts && /opt/sitescripts/ensure_dep
    endencies.py -q", | 
|  57     environment => hiera('cron::environment', []), |  57     environment => hiera('cron::environment', []), | 
|  58     user => root, |  58     user => root, | 
|  59     require => Exec["fetch_sitescripts"], |  59     require => Exec["fetch_sitescripts"], | 
|  60   } |  60   } | 
|  61 } |  61 } | 
| OLD | NEW |