-
Notifications
You must be signed in to change notification settings - Fork 9
/
galaxy_elastic_cluster.yaml
168 lines (155 loc) · 4.85 KB
/
galaxy_elastic_cluster.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
tosca_definitions_version: tosca_simple_yaml_1_0
imports:
- indigo_custom_types: https://raw.githubusercontent.com/indigo-dc/tosca-types/master/custom_types.yaml
description: >
TOSCA test for launching a Virtual Elastic Cluster. It will launch
a single front-end that will be in change of managing the elasticity
using the specified LRMS (torque, sge, slurm and condor) workload.
topology_template:
inputs:
wn_num:
type: integer
description: Maximum number of WNs in the elastic cluster
default: 5
required: yes
fe_cpus:
type: integer
description: Numer of CPUs for the front-end node
default: 1
required: yes
fe_mem:
type: scalar-unit.size
description: Amount of Memory for the front-end node
default: 1 GB
required: yes
wn_cpus:
type: integer
description: Numer of CPUs for the WNs
default: 1
required: yes
wn_mem:
type: scalar-unit.size
description: Amount of Memory for the WNs
default: 1 GB
required: yes
hybrid:
type: boolean
description: Flag to specify that this cluster will work in an hybrid environment
default: false
required: false
admin_email:
type: string
description: email of the admin user
default: admin@admin.com
admin_api_key:
type: string
description: key to access the API with admin role
default: not_very_secret_api_key
version:
type: string
description: galaxy version to install
default: master
instance_description:
type: string
description: galaxy instance description
default: INDIGO Galaxy test
instance_key_pub:
type: string
description: galaxy instance ssh public key
default: your_ssh_public_key
export_dir:
type: string
description: path to store galaxy data
default: /export
node_templates:
elastic_cluster_front_end:
type: tosca.nodes.indigo.ElasticCluster
properties:
deployment_id: orchestrator_deployment_id
iam_access_token: iam_access_token
iam_clues_client_id: iam_clues_client_id
iam_clues_client_secret: iam_clues_client_secret
hybrid: { get_input: hybrid }
requirements:
- lrms: lrms_front_end
- wn: wn_node
# it needs a host container
- host: lrms_server
galaxy_portal:
type: tosca.nodes.indigo.GalaxyPortal
properties:
admin_email: { get_input: admin_email }
admin_api_key: { get_input: admin_api_key }
version: { get_input: version }
instance_description: { get_input: instance_description }
instance_key_pub: { get_input: instance_key_pub }
requirements:
- lrms: lrms_front_end
# it needs a host container
- host: lrms_wn
lrms_front_end:
type: tosca.nodes.indigo.LRMS.FrontEnd.Slurm
properties:
wn_ips: { get_attribute: [ lrms_wn, private_address ] }
hybrid: { get_input: hybrid }
requirements:
- host: lrms_server
lrms_server:
type: tosca.nodes.indigo.Compute
capabilities:
endpoint:
properties:
dns_name: slurmserver
network_name: PUBLIC
ports:
http_port:
protocol: tcp
source: 80
host:
properties:
num_cpus: { get_input: fe_cpus }
mem_size: { get_input: fe_mem }
os:
properties:
image: linux-ubuntu-14.04-vmi
wn_node:
type: tosca.nodes.indigo.LRMS.WorkerNode.Slurm
properties:
front_end_ip: { get_attribute: [ lrms_server, private_address, 0 ] }
public_front_end_ip: { get_attribute: [ lrms_server, public_address, 0 ] }
hybrid: { get_input: hybrid }
capabilities:
wn:
properties:
min_instances: 1
max_instances: { get_input: wn_num }
default_instances: 1
requirements:
- host: lrms_wn
galaxy_wn:
type: tosca.nodes.indigo.GalaxyWN
properties:
export_dir: { get_input: export_dir }
front_end_ip: { get_attribute: [ lrms_server, private_address, 0 ] }
requirements:
- host: lrms_wn
lrms_wn:
type: tosca.nodes.indigo.Compute
capabilities:
scalable:
properties:
count: 0
host:
properties:
num_cpus: { get_input: wn_cpus }
mem_size: { get_input: wn_mem }
os:
properties:
image: linux-ubuntu-14.04-vmi
outputs:
galaxy_url:
value: { concat: [ 'http://', get_attribute: [ lrms_server, public_address, 0 ], '/galaxy' ] }
cluster_ip:
value: { get_attribute: [ lrms_server, public_address, 0 ] }
cluster_creds:
value: { get_attribute: [ lrms_server, endpoint, credential, 0 ] }