2020-08-18 13:27:55 +00:00
|
|
|
defaults = {
|
|
|
|
'apt': {
|
|
|
|
'repos': {
|
|
|
|
'jenkins': {
|
2021-04-30 10:49:59 +00:00
|
|
|
'items': {
|
2020-08-30 10:06:19 +00:00
|
|
|
'deb https://pkg.jenkins.io/{os}-stable binary/',
|
2021-04-30 10:49:59 +00:00
|
|
|
},
|
2020-05-09 11:08:34 +00:00
|
|
|
},
|
2020-08-18 13:27:55 +00:00
|
|
|
},
|
|
|
|
'packages': {
|
|
|
|
'openjdk-11-jre': {},
|
|
|
|
'jenkins': {
|
|
|
|
'needs': {
|
|
|
|
'pkg_apt:openjdk-11-jre',
|
2020-05-09 11:08:34 +00:00
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2020-08-18 13:27:55 +00:00
|
|
|
},
|
2020-11-13 11:37:26 +00:00
|
|
|
'backups': {
|
|
|
|
'paths': {
|
|
|
|
'/var/lib/jenkins',
|
|
|
|
},
|
|
|
|
},
|
2021-07-11 13:29:42 +00:00
|
|
|
'zfs': {
|
|
|
|
'datasets': {
|
|
|
|
'tank/jenkins': {
|
|
|
|
'mountpoint': '/var/lib/jenkins',
|
|
|
|
'needed_by': {
|
|
|
|
'pkg_apt:jenkins',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2020-08-18 13:27:55 +00:00
|
|
|
}
|
2021-07-16 12:20:01 +00:00
|
|
|
|
|
|
|
|
|
|
|
@metadata_reactor.provides(
|
|
|
|
'nginx/vhosts/jenkins-ci',
|
|
|
|
)
|
|
|
|
def nginx(metadata):
|
|
|
|
if not node.has_bundle('nginx'):
|
|
|
|
raise DoNotRunAgain
|
|
|
|
|
|
|
|
return {
|
|
|
|
'nginx': {
|
|
|
|
'vhosts': {
|
|
|
|
'jenkins-ci': {
|
|
|
|
'domain': metadata.get('jenkins-ci/domain'),
|
|
|
|
'locations': {
|
|
|
|
'/': {
|
|
|
|
'target': 'http://localhost:22010/',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'website_check_path': '/login',
|
|
|
|
'website_check_string': 'Welcome to Jenkins',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|