From 57b2ca6316cf9867280777b05adf863e4acc133d Mon Sep 17 00:00:00 2001 From: Magnus Andersson Date: Thu, 29 Aug 2024 11:02:30 +0200 Subject: [PATCH] multinode-db1 test: Add rclone and statistics remote --- manifests/multinode_db.pp | 34 +--------------------------------- 1 file changed, 1 insertion(+), 33 deletions(-) diff --git a/manifests/multinode_db.pp b/manifests/multinode_db.pp index 8ec056e..8e6563e 100644 --- a/manifests/multinode_db.pp +++ b/manifests/multinode_db.pp @@ -15,12 +15,8 @@ class sunetdrive::multinode_db(){ } } if $facts["networking"]["fqdn"] =~ /^multinode-db1\.drive\.(test\.){1}sunet\.se$/ { - $statistics_secret = safe_hiera('statistics_secret') notify { 'hostmessage': - message => 'We are on multinode-db1. Set up statistics environment.', - } - $custdata=$customers.reduce({}) |$memo, $value| { - $memo + {$value => lookup($value)} + message => "We are on multinode-db1. Set up statistics environment.", } $rclone_url = 'https://downloads.rclone.org/rclone-current-linux-amd64.deb' $local_path = '/tmp/rclone-current-linux-amd64.deb' @@ -41,33 +37,5 @@ class sunetdrive::multinode_db(){ group => 'root', mode => '0600', } - file { '/root/tasks/listusersbydep.sh': - ensure => file, - content => template('sunetdrive/mariadb/listusersdep.sh.erb'), - owner => 'root', - group => 'root', - mode => '0700', - } - file { '/root/tasks/genusersondepartmentlists.sh': - ensure => file, - content => template('sunetdrive/mariadb/genuserdeplists.sh.erb'), - owner => 'root', - group => 'root', - mode => '0700', - } - file {'/opt/mariadb/statistics/custdata.json': - ensure => file, - content => template('sunetdrive/mariadb/custconfig.json.erb'), - owner => 'root', - group => 'root', - mode => '0600', - } - sunet::scriptherder::cronjob { 'genuserdeplists': - cmd => '/root/tasks/genusersondepartmentlists.sh', - hour => '2', - minute => '5', - ok_criteria => ['exit_status=0','max_age=30h'], - warn_criteria => ['exit_status=1', 'max_age=60h'], - } } }