/
CMS-HTCondor-dodas.yaml
245 lines (204 loc) · 6.76 KB
/
CMS-HTCondor-dodas.yaml
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
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
tosca_definitions_version: tosca_simple_yaml_1_0
imports:
- indigo_custom_types: https://raw.githubusercontent.com/indigo-dc/tosca-types/dodas_roll/custom_types.yaml
description: TOSCA template for a complete CMS Site over Mesos orchestrator
topology_template:
inputs:
# Marathon and Mesos related configuration parameters
marathon_username:
type: string
default: "Marathon-user"
marathon_password:
type: string
default: "changeme"
mesos_username:
type: string
default: "Mesos-user"
mesos_password:
type: string
default: "changeme"
number_of_masters:
type: integer
default: 1
num_cpus_master:
type: integer
default: 2
mem_size_master:
type: string
default: "4 GB"
number_of_slaves:
type: integer
default: 4
num_cpus_slave:
type: integer
default: 4
mem_size_slave:
type: string
default: "8 GB"
number_of_lbs:
type: integer
default: 1
num_cpus_lb:
type: integer
default: 2
mem_size_lb:
type: string
default: "2 GB"
server_image:
type: string
default: "ost://horizon.cloud.cnaf.infn.it/0b18691b-2c67-4800-876e-60802024c64f"
# default: "ost://cloud.recas.ba.infn.it/1113d7e8-fc5d-43b9-8d26-61906d89d479"
####
# IAM related configurations to enable the OIDC to X.509 certificate translation
iam_token:
type: string
default: "DODAS-IAM.Token"
iam_client_id:
type: string
default: "IAM-Client-ID"
iam_client_secret:
type: string
default: "IAM-Client-Secret"
# CMS specific configurations
cms_local_site:
type: string
default: "T3_IT_Opportunistic_dodas"
cms_stageoutsite:
type: string
default: "T1_IT_CNAF"
cms_stageoutprotocol:
type: string
default: "srmv2"
cms_stageoutcommand:
type: string
default: "gfal2"
cms_phedexnode:
type: string
default: "T1_IT_CNAF_Disk"
cms_xrd_readserver:
type: string
default: "xrootd.ba.infn.it"
# DODAS-Monitoring specific params (NOTE this is optional)
monitordb_ip:
type: string
default: "ES-Endpoint"
elasticsearch_secret:
type: string
default: "ES-secret"
node_templates:
mesos_master:
type: tosca.nodes.indigo.MesosMaster
properties:
mesos_username: { get_input: mesos_username }
mesos_password: { get_input: mesos_password }
marathon_username: { get_input: marathon_username }
marathon_password: { get_input: marathon_password }
mesos_masters_list: { get_attribute: [ mesos-master-server, private_address ] }
requirements:
- host: mesos-master-server
cms_services:
type: tosca.nodes.indigo.CmsServices
properties:
marathon_password: { get_input: marathon_password }
marathon_username: { get_input: marathon_username }
mysquid_host: { get_attribute: [ mesos-lb-server, private_address, 0 ] }
proxycache_host: { get_attribute: [ mesos-lb-server, private_address, 0 ] }
iam_access_token: { get_input: iam_token }
iam_client_id: { get_input: iam_client_id }
iam_client_secret: { get_input: iam_client_secret }
master_ips: { get_attribute: [ mesos-master-server, private_address ] }
cms_local_site: { get_input: cms_local_site }
requirements:
- host: mesos_master
mesos_slave:
type: tosca.nodes.indigo.MesosSlave
properties:
master_ips: { get_attribute: [ mesos-master-server, private_address ] }
front_end_ip: { get_attribute: [ mesos-master-server, private_address, 0 ] }
requirements:
- host: mesos-slave-server
cms_wn:
type: tosca.nodes.indigo.CmsWnConfig
properties:
mysquid_host: { get_attribute: [ mesos-lb-server, private_address, 0 ] }
proxycache_host: { get_attribute: [ mesos-lb-server, private_address, 0 ] }
cms_local_site: { get_input: cms_local_site }
cms_stageoutsite: { get_input: cms_stageoutsite }
cms_stageoutprotocol: { get_input: cms_stageoutprotocol }
cms_stageoutcommand: { get_input: cms_stageoutcommand }
cms_phedexnode: { get_input: cms_phedexnode }
cms_xrd_readserver: { get_input: cms_xrd_readserver }
monitordb_ip: { get_input: monitordb_ip }
elasticsearch_secret: { get_input: elasticsearch_secret }
requirements:
- host: mesos_slave
mesos_load_balancer:
type: tosca.nodes.indigo.MesosLoadBalancer
properties:
master_ips: { get_attribute: [ mesos-master-server, private_address ] }
marathon_username: { get_input: marathon_username }
marathon_password: { get_input: marathon_password }
requirements:
- host: mesos-lb-server
- dependency: mesos_master
mesos-master-server:
type: tosca.nodes.indigo.Compute
capabilities:
endpoint:
properties:
network_name: PUBLIC
dns_name: mesosserverpublic
ports:
mesos_port:
protocol: tcp
source: 5050
marathon_port:
protocol: tcp
source: 8443
scalable:
properties:
count: { get_input: number_of_masters }
host:
properties:
num_cpus: { get_input: num_cpus_master }
mem_size: { get_input: mem_size_master }
os:
properties:
image: { get_input: server_image }
mesos-slave-server:
type: tosca.nodes.indigo.Compute
capabilities:
scalable:
properties:
count: { get_input: number_of_slaves }
host:
properties:
num_cpus: { get_input: num_cpus_slave }
mem_size: { get_input: mem_size_slave }
os:
properties:
image: { get_input: server_image }
mesos-lb-server:
type: tosca.nodes.indigo.Compute
capabilities:
endpoint:
properties:
network_name: PUBLIC
dns_name: mesoslb
scalable:
properties:
count: { get_input: number_of_lbs }
host:
properties:
num_cpus: { get_input: num_cpus_lb }
mem_size: { get_input: mem_size_lb }
os:
properties:
image: { get_input: server_image }
outputs:
mesos_lb_ip:
value: { get_attribute: [ mesos-lb-server, private_address, 0 ] }
mesos_endpoint:
value: { concat: [ 'http://', get_attribute: [ mesos-master-server, public_address, 0 ], ':5050' ] }
marathon_endpoint:
value: { concat: [ 'https://', get_attribute: [ mesos-master-server, public_address, 0 ], ':8443' ] }