-
Notifications
You must be signed in to change notification settings - Fork 166
/
Copy pathmain.yml
139 lines (129 loc) · 3.59 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
---
#
#
#
init: {
aix: ['aix71', 'aix72', 'aix73'],
centos6: 'centos6',
debian: 'debian7',
freebsd: 'freebsd',
ibmi: 'ibmi73',
macos: 'macos',
systemd: ['centos7', 'debian8', 'debian9', 'debian10', 'fedora', 'rhel7', 'rhel8', 'ubuntu1604', 'ubuntu1804','ubuntu2204'],
svc: 'smartos',
upstart: ['ubuntu12', 'ubuntu1404'],
zos_start: 'zos'
}
jenkins_init: {
aix: {
dest: '/etc/rc.d/rc2.d/S20jenkins',
src: 'aix.rc2.j2',
mode: '0555'
},
centos6: {
dest: '/etc/init.d/jenkins',
src: 'centos6.initd.j2',
mode: '0755'
},
debian: {
dest: '/etc/init.d/jenkins',
src: 'sysvinit.initd.j2',
mode: '0755'
},
freebsd: {
dest: '/usr/local/etc/rc.d/jenkins',
src: 'freebsd.initd.j2',
mode: '0755'
},
macos: {
dest: '/Library/LaunchDaemons/org.nodejs.osx.jenkins.plist',
src: 'org.nodejs.osx.jenkins.plist',
mode: '0755'
},
svc: {
dest: '/home/{{ server_user }}/jenkins_manifest.xml',
src: 'jenkins_manifest.xml.j2'
},
systemd: {
dest: '/lib/systemd/system/jenkins.service',
src: 'systemd.service.j2'
},
upstart: {
dest: '/etc/init/jenkins.conf',
src: 'upstart.j2'
},
zos_start: {
dest: '{{ home }}/{{ server_user }}/start.sh.utf8',
src: 'zos_start.j2'
},
ibmi: {
dest: '{{ home }}/{{ server_user }}/jenkins-start.sh',
src: 'ibmi_start.j2'
},
}
# if you fail here, it means it cant map your os or os family to a init system
# the best thing to do would be throwing, but the default case seems to be
# called regardless of success.
init_type: "{{ os|match_key(init, raise_error=False)|default(os|stripversion|match_key(init, raise_error=False)) }}"
jenkins: "{{ jenkins_init[init_type] }}"
needs_monit: [
'centos6',
'debian7',
]
# some os'es needs different paths to java. add them here.
java_path: {
'ibmi73': '/QOpenSys/pkgs/lib/jvm/openjdk-11/bin/java',
'macos10.10': 'java',
'macos10.11': 'java',
'macos10.12': 'java',
'macos10.13': 'java',
'macos10.14': 'java',
'macos10.15': 'java',
'macos11': 'java',
# Currently hardcoded untill adopt have their build available
'macos11.0': '/Users/{{ ansible_user }}/zulu8.52.0.23-ca-jdk8.0.282-macosx_aarch64/bin/java',
'smartos15': '/opt/local/java/openjdk8/bin/java',
'smartos16': '/opt/local/java/openjdk8/bin/java',
'smartos17': '/opt/local/java/openjdk8/bin/java',
'smartos18': '/opt/local/java/openjdk8/bin/java',
'smartos20': '/opt/local/java/openjdk8/bin/java',
'zos24': '/usr/lpp/java/J8.0_64/bin/java'
}
# same for bash. will default to /bin/bash if you don't set it
bash_path: {
aix: '/usr/bin/ksh',
freebsd: '/usr/local/bin/bash',
zos: 'bash'
}
raspberry_pi: {
nfs_root_server: '192.168.1.10',
nfs_root_share_root: '/exports/nodejs/pi',
containers: {
armv6l: [
{ name: 'wheezy', template: 'rpi_wheezy.Dockerfile.j2' },
{ name: 'jessie', template: 'rpi_jessie.Dockerfile.j2' }
],
armv7l: [
{ name: 'stretch', template: 'rpi_stretch.Dockerfile.j2' },
{ name: 'buster', template: 'rpi_buster.Dockerfile.j2' }
],
arm64: [
{ name: 'stretch', template: 'rpi_stretch.Dockerfile.j2' },
{ name: 'buster', template: 'rpi_buster.Dockerfile.j2' }
]
}
}
scaleway_armv7: {
containers: [
{ name: 'jessie', template: 'armv7_jessie.Dockerfile.j2' },
{ name: 'stretch', template: 'armv7_stretch.Dockerfile.j2' }
]
}
# primarily for raspberry pi workers, some arm64 workers may need `server_jobs` defined in inventory
# to override these low numbers
jobs_variants: {
armv6l: '1',
armv7l: '2',
arm64: '3',
smartos: '2'
}