diff options
Diffstat (limited to 'modules/buildsystem/manifests')
-rw-r--r-- | modules/buildsystem/manifests/buildnode.pp | 3 | ||||
-rw-r--r-- | modules/buildsystem/manifests/iurt.pp | 7 | ||||
-rw-r--r-- | modules/buildsystem/manifests/iurt/config.pp | 3 | ||||
-rw-r--r-- | modules/buildsystem/manifests/iurt/upload.pp | 5 | ||||
-rw-r--r-- | modules/buildsystem/manifests/iurt/user.pp | 7 | ||||
-rw-r--r-- | modules/buildsystem/manifests/mainnode.pp | 2 | ||||
-rw-r--r-- | modules/buildsystem/manifests/sshkeys.pp | 6 | ||||
-rw-r--r-- | modules/buildsystem/manifests/var/iurt.pp | 4 |
8 files changed, 19 insertions, 18 deletions
diff --git a/modules/buildsystem/manifests/buildnode.pp b/modules/buildsystem/manifests/buildnode.pp index 3085a513..7e3e657e 100644 --- a/modules/buildsystem/manifests/buildnode.pp +++ b/modules/buildsystem/manifests/buildnode.pp @@ -2,10 +2,11 @@ class buildsystem::buildnode { include buildsystem::base include buildsystem::iurt include buildsystem::var::scheduler + include buildsystem::var::iurt include buildsystem::sshkeys # permit to scheduler to run iurt ssh::auth::server { $buildsystem::var::scheduler::login: - user => $buildsystem::iurt::user::login, + user => $buildsystem::var::iurt::login, } } diff --git a/modules/buildsystem/manifests/iurt.pp b/modules/buildsystem/manifests/iurt.pp index e0856a23..3a428127 100644 --- a/modules/buildsystem/manifests/iurt.pp +++ b/modules/buildsystem/manifests/iurt.pp @@ -2,13 +2,12 @@ class buildsystem::iurt { include sudo include buildsystem::iurt::user include buildsystem::iurt::packages - $login = $buildsystem::iurt::user::login - $homedir = $buildsystem::iurt::user::homedir + include buildsystem::var::iurt - ssh::auth::client { $login: } + ssh::auth::client { $buildsystem::var::iurt::login: } # remove old build directory - tidy { "$homedir/iurt": + tidy { "${buildsystem::var::iurt::homedir}/iurt": age => '8w', recurse => true, matches => ['[0-9][0-9].*\..*\..*\.[0-9]*','log','*.rpm','*.log','*.mga[0-9]+'], diff --git a/modules/buildsystem/manifests/iurt/config.pp b/modules/buildsystem/manifests/iurt/config.pp index 88c08b66..1d75c32e 100644 --- a/modules/buildsystem/manifests/iurt/config.pp +++ b/modules/buildsystem/manifests/iurt/config.pp @@ -1,7 +1,8 @@ define buildsystem::iurt::config() { + include buildsystem::var::iurt $distribution = $name # TODO rename the variable too in template - $build_login = $buildsystem::iurt::user::login + $build_login = $buildsystem::var::iurt::login file { "/etc/iurt/build/$distribution.conf": owner => $build_login, diff --git a/modules/buildsystem/manifests/iurt/upload.pp b/modules/buildsystem/manifests/iurt/upload.pp index 187c3bb8..94921223 100644 --- a/modules/buildsystem/manifests/iurt/upload.pp +++ b/modules/buildsystem/manifests/iurt/upload.pp @@ -1,8 +1,5 @@ class buildsystem::iurt::upload { - $login = $buildsystem::iurt::user::login - $homedir = $buildsystem::iurt::user::homedir - $sched_login = $buildsystem::var::scheduler::login - + include buildsystem::var::iurt file { '/etc/iurt/upload.conf': require => File['/etc/iurt'], content => template('buildsystem/upload.conf'), diff --git a/modules/buildsystem/manifests/iurt/user.pp b/modules/buildsystem/manifests/iurt/user.pp index b169ee2d..0da84743 100644 --- a/modules/buildsystem/manifests/iurt/user.pp +++ b/modules/buildsystem/manifests/iurt/user.pp @@ -1,9 +1,8 @@ class buildsystem::iurt::user { - $login = 'iurt' - $homedir = "/home/$login" + include buildsystem::var::iurt - buildsystem::sshuser { $login: - homedir => $homedir, + buildsystem::sshuser { $buildsystem::var::iurt::login: + homedir => $buildsystem::var::iurt::homedir, comment => 'System user used to run build bots', } diff --git a/modules/buildsystem/manifests/mainnode.pp b/modules/buildsystem/manifests/mainnode.pp index d00704a5..b684217f 100644 --- a/modules/buildsystem/manifests/mainnode.pp +++ b/modules/buildsystem/manifests/mainnode.pp @@ -12,7 +12,7 @@ class buildsystem::mainnode { $sched_login = $buildsystem::var::scheduler::login $sched_home_dir = $buildsystem::var::scheduler::homedir - $build_login = $buildsystem::iurt::user::login + $build_login = $buildsystem::var::iurt::login ssh::auth::client { $sched_login: } diff --git a/modules/buildsystem/manifests/sshkeys.pp b/modules/buildsystem/manifests/sshkeys.pp index a3f4a41c..14edbe2f 100644 --- a/modules/buildsystem/manifests/sshkeys.pp +++ b/modules/buildsystem/manifests/sshkeys.pp @@ -1,13 +1,13 @@ class buildsystem::sshkeys { include ssh::auth include buildsystem::var::scheduler - include buildsystem::iurt::user + include buildsystem::var::iurt ssh::auth::key { $buildsystem::var::scheduler::login: home => $buildsystem::var::scheduler::homedir, } - ssh::auth::key { $buildsystem::iurt::user::login: - home => $buildsystem::iurt::user::homedir + ssh::auth::key { $buildsystem::var::iurt::login: + home => $buildsystem::var::iurt::homedir } } diff --git a/modules/buildsystem/manifests/var/iurt.pp b/modules/buildsystem/manifests/var/iurt.pp new file mode 100644 index 00000000..3f91c676 --- /dev/null +++ b/modules/buildsystem/manifests/var/iurt.pp @@ -0,0 +1,4 @@ +class buildsystem::var::iurt( + $login = 'iurt', + $homedir = '/home/iurt' +) { } |