Files
confdroid_jenkins/manifests/main/yumrepo.pp

30 lines
893 B
ObjectPascal
Raw Normal View History

2026-04-16 14:30:16 +02:00
## confdroid_jenkins::main::yumrepo.pp
# Module name: confdroid_jenkins
# Author: 12ww1160 (12ww1160@confdroid.com)
2025-05-05 17:02:29 +02:00
# @summary Class manages yum repos for the installation
##############################################################################
2026-04-16 14:30:16 +02:00
class confdroid_jenkins::main::yumrepo (
2025-05-05 17:02:29 +02:00
2026-04-16 14:30:16 +02:00
) inherits confdroid_jenkins::params {
if $fqdn == $js_host_fqdn {
yumrepo { 'jenkins':
2026-04-16 15:41:22 +02:00
descr => 'Jenkins-stable',
baseurl => $js_base_url,
gpgcheck => $js_gpg_check,
2026-04-16 15:55:52 +02:00
repo_gpgcheck => $js_gpg_repo_check,
2026-04-16 15:41:22 +02:00
enabled => $js_repo_enabled,
}
2025-05-05 17:02:29 +02:00
# import rpm key
2026-04-16 15:41:22 +02:00
exec { $js_key:
command => "rpm --import ${js_base_url}/${js_key}",
path => '/bin:/usr/bin:/sbin:/usr/sbin',
cwd => '/tmp',
user => 'root',
unless => "rpm -q ${js_key_code} 2>/dev/null",
require => Yumrepo['jenkins'],
}
2025-05-05 17:02:29 +02:00
}
}