Franziska Kunsmann
72f148425a
All checks were successful
bundlewrap/pipeline/head This commit looks good
42 lines
919 B
Python
42 lines
919 B
Python
directories = {
|
|
'/var/lib/jenkins': {
|
|
'owner': 'jenkins',
|
|
'group': 'jenkins',
|
|
'needs': {
|
|
'pkg_apt:jenkins',
|
|
},
|
|
},
|
|
'/var/lib/jenkins/.ssh': {
|
|
'mode': '0755',
|
|
'owner': 'git',
|
|
'group': 'git',
|
|
},
|
|
}
|
|
|
|
files = {
|
|
'/etc/default/jenkins': {
|
|
'triggers': {
|
|
'svc_systemd:jenkins:restart',
|
|
},
|
|
},
|
|
'/var/lib/jenkins/.ssh/config': {
|
|
'source': 'ssh-config',
|
|
},
|
|
}
|
|
|
|
if node.metadata.get('jenkins-ci/install_ssh_key', False):
|
|
files['/var/lib/jenkins/.ssh/id_ed25519'] = {
|
|
'content': repo.vault.decrypt_file(f'jenkins-ci/files/ssh-keys/{node.name}.key.vault'),
|
|
'mode': '0600',
|
|
'owner': 'jenkins',
|
|
'group': 'jenkins',
|
|
}
|
|
|
|
svc_systemd = {
|
|
'jenkins': {
|
|
'needs': {
|
|
'directory:/var/lib/jenkins',
|
|
'pkg_apt:jenkins',
|
|
},
|
|
},
|
|
}
|