From 699413b099016ff5e60a3810bd1fa26b4b5a95b6 Mon Sep 17 00:00:00 2001 From: Miguel Caballer Date: Mon, 23 May 2022 10:14:50 +0200 Subject: [PATCH 01/31] Add minio recipe --- app/static/images/k8s_minio.png | Bin 0 -> 26040 bytes tosca-templates/k8s_minio.parameters.yaml | 50 ++++++ tosca-templates/k8s_minio.yaml | 203 ++++++++++++++++++++++ 3 files changed, 253 insertions(+) create mode 100644 app/static/images/k8s_minio.png create mode 100644 tosca-templates/k8s_minio.parameters.yaml create mode 100644 tosca-templates/k8s_minio.yaml diff --git a/app/static/images/k8s_minio.png b/app/static/images/k8s_minio.png new file mode 100644 index 0000000000000000000000000000000000000000..d9d1af3ab8b56196f37ce83c625f68053c2a00d8 GIT binary patch literal 26040 zcmeFZWmMbIvNs&uDefAaB7xviEV#QADDLh~C{m=jySo-EE`?&nwZ)4UcZ#)7+H>x? z=dSnpa@TsFZzrsTfA*f4J@XscvNlAismNlXlc56u04#Yqhz9KU1MKaCiVXW)NjW_f?o|i zQUnC$ZwymzY=rmzUR|Jej(%dk;0^rs?fCJ5TI_`w=lMPN&$_2wNyorouHV06@_Lt? zdkqi#i%W2&d%kU8+?<7LJUsyeI6*y{4eN(*%0W~6M|aQpmYel+<%CcBZZ}t*Z+_># ztp12`C(o5fkhJfvumMN^9Ls^#!x9h|CGkT#fcoc>oZ#m(IlY99+PSIt$;i5htl-C@ zUg_O^?_NlCP)>{Gr;W3%jbJCb)v3rJ{lMpL z?~jjr<7_f~Y0Evy4_u$`DC@IVB|kdF6_U37S8D?c#?>m1PHMUlIG z4N(uf>ZxlWF^e1iJjTyem$CkWCHw2PLiC%(d>3yY@k)pf1~D++i1Csf{xXI#Y%PZOhd~e{4dfW~&UuH(;4!|TPMaKX z?FvMRGc!0Lle#O&I2g>=`YK|bm41K(9sd+Gk)c;;)QVD84K>*{9Ldij7vxc3ZBH>P zP1ErsO=Ek_)no_%SzU9YF3qlGQOBQ>y=7IQN$0hFcPy1ZJdff>WB;S>_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%)4h2KLoUY_GCdvaRMX+1R!Xgt|uf?$lH{X>3)nlUMk|S) zsU}?nc4ExS0A6Xb4Vxj(6177v2f!8TJ=v;`^#Inx&aNwVv?-y;)+5ROZ>$Ks`~2+rJ`S)@3G5WkNotIT<3Q-LUYQ(kD_eAB zJEcgk1#lk`p2`UY^tIbeezhXfx~(n@TsgbWJAuUBf z(+E-mbqy9Ot1YbBYGO~l#64GJ@YvygOg`1XYi-C6yKJnFFFq$g%E9?VB04JCqx<1O z7snmcVHEcR_<1xgao6+JykKqousc`>bP@dI54%!Un#K>lum`i(*$zDhAf>$$G)XHW z+V7lW05i_;^8Me*rZt=6{Jp34P&9FPm2P++5C7qZ*+>rvg1xKpmqc__J~-l@FyrF5 zgNm;|1mGo~A@~R9r=xdO8tguz~>`cKe>B_N$#LX9H;G|w2Ql`?q zM6~ay_J=zqTpZ_WeA97EgI=Fk$G@3bN9G|o+$%%yu--bBe3qbSqHXR12H@3zF#|ok ze6vXn@#dfR>%d)?X2`s80U-!G09;N)i;i|bxI}kxBG~I!0C+iJGVc6y6&8FNr(ImO^B zbJK<4AqjgQ$lQ)9-zB<>6M^gz*n1k@4EO}TJ0l%EQU#bhj^wBJ)^YpgnaE1l06XpX z{`NQv&Lz4F7YCC)3gDLjR-W9?pnI>%klj;{zU9gQGJJ#^3sSjPSDj$*9r&@T4_uMa~^|7bhUm z4cMOeKS+tRSb|&q1=hB(O4kU6hoA{WVek9++gCm0(IvVI7i}Xu!QO*$C+tH?j>f0A zW3co69|f>nMF8Lu-Gz&eC%guGqm3W!|Ix`9fPF+{xjpT|g$oxhT)1%I!i5VLE?l^9 e;ljlUg8v7xcYn067@GM20000" + default: "" + + admin_token: + type: string + description: Access Token for the Kubernetes admin user + default: not_very_secret_token + kube_version: + type: string + description: Version of Kubernetes to install + default: "1.23.6" + constraints: + - valid_values: [ "1.23.6", "1.22.9", "1.21.12" ] + kube_cert_manager: + type: boolean + description: Flag to install Cert-Manager + default: false + constraints: + - valid_values: [ false, true ] + kube_cert_user_email: + type: string + description: Email to be used in the Let's Encrypt issuer + default: "jhondoe@server.com" + + minio_accesskey: + type: string + description: Access key credential for object storage and web access + default: minio + minio_secretkey: + type: string + description: Secret key credential for object storage and web access + default: minio123 + + node_templates: + + argo: + type: tosca.nodes.ec3.Application + interfaces: + Standard: + configure: + implementation: https://raw.githubusercontent.com/grycap/ec3/tosca/tosca/artifacts/minio.yml + inputs: + minio_accesskey: { get_input: minio_accesskey } + minio_secretkey: { get_input: minio_secretkey } + enable_ingress: true + requirements: + - host: front + - dependency: lrms_front_end + + lrms_front_end: + type: tosca.nodes.indigo.LRMS.FrontEnd.Kubernetes + capabilities: + endpoint: + properties: + ports: + https_port: + protocol: tcp + source: 80 + https_port: + protocol: tcp + source: 443 + kube_port: + protocol: tcp + source: 6443 + properties: + admin_username: kubeuser + install_nfs_client: true + admin_token: { get_input: admin_token } + install_kubeapps: false + version: { get_input: kube_version } + nvidia_support: false + cert_manager: { get_input: kube_cert_manager } + cert_user_email: { get_input: kube_cert_user_email } + cri_runtime: docker + requirements: + - host: front + + front: + type: tosca.nodes.indigo.Compute + capabilities: + endpoint: + properties: + dns_name: kubeserver + network_name: PUBLIC + host: + properties: + num_cpus: { get_input: fe_cpus } + mem_size: { get_input: fe_mem } + instance_type: { get_input: fe_instance_type } + os: + properties: + distribution: ubuntu + type: linux + requirements: + - local_storage: + node: fe_block_storage + relationship: + type: AttachesTo + properties: + location: /pv + + fe_block_storage: + type: tosca.nodes.BlockStorage + properties: + size: { get_input: disk_size } + volume_id: { get_input: volume_id } + + wn_node: + type: tosca.nodes.indigo.LRMS.WorkerNode.Kubernetes + properties: + front_end_ip: { get_attribute: [ front, private_address, 0 ] } + version: { get_input: kube_version } + nvidia_support: false + cri_runtime: docker + requirements: + - host: wn + + wn: + type: tosca.nodes.indigo.Compute + capabilities: + scalable: + properties: + count: { get_input: wn_num } + host: + properties: + num_cpus: { get_input: wn_cpus } + mem_size: { get_input: wn_mem } + instance_type: { get_input: wn_instance_type } + os: + properties: + distribution: ubuntu + type: linux + + outputs: + k8s_dashboard_endpoint: + value: { concat: [ 'https://', get_attribute: [ front, public_address, 0 ], '/dashboard/' ] } + argo_server_endpoint: + value: { concat: [ 'https://', get_attribute: [ front, public_address, 0 ], '/' ] } + argo_token: + value: { get_attribute: [ front, ansible_output, argo_front_conf_front, tasks ,'Show ARGO Token', output] } + From f529104437088e63bf6dd99dda7429a391b935b9 Mon Sep 17 00:00:00 2001 From: Miguel Caballer Date: Mon, 23 May 2022 10:24:44 +0200 Subject: [PATCH 02/31] Fix minio recipe --- tosca-templates/k8s_minio.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tosca-templates/k8s_minio.yaml b/tosca-templates/k8s_minio.yaml index 60317a6a5..15db36e28 100644 --- a/tosca-templates/k8s_minio.yaml +++ b/tosca-templates/k8s_minio.yaml @@ -97,6 +97,10 @@ topology_template: argo: type: tosca.nodes.ec3.Application + artifacts: + docker_role: + file: grycap.kubeminio + type: tosca.artifacts.AnsibleGalaxy.role interfaces: Standard: configure: From d123deac23a7b2757a55cbe27febb56dfdb7a625 Mon Sep 17 00:00:00 2001 From: micafer Date: Tue, 24 May 2022 09:55:27 +0200 Subject: [PATCH 03/31] Enable addons selection --- app/__init__.py | 49 ++++++++++++++++++++++---- app/templates/createdep.html | 13 +++++++ app/templates/portfolio.html | 37 +++++++++++++++++++- tosca-templates/kubernetes.yaml | 2 ++ tosca-templates/minio.parameters.yaml | 9 +++++ tosca-templates/minio.yaml | 50 +++++++++++++++++++++++++++ 6 files changed, 152 insertions(+), 8 deletions(-) create mode 100644 tosca-templates/minio.parameters.yaml create mode 100644 tosca-templates/minio.yaml diff --git a/app/__init__.py b/app/__init__.py index d0edfb116..d3614ada4 100644 --- a/app/__init__.py +++ b/app/__init__.py @@ -24,6 +24,7 @@ import io import os import logging +import copy from requests.exceptions import Timeout from werkzeug.middleware.proxy_fix import ProxyFix from flask_dance.consumer import OAuth2ConsumerBlueprint @@ -177,7 +178,7 @@ def home(): session['userid'] = "a_very_long_user_id_00000000000000000000000000000000000000000000@egi.es" session['username'] = "username" session['gravatar'] = "" - return render_template('portfolio.html', templates=templates) + return render_template('portfolio.html', templates=templates, parent=None) else: if not oidc_blueprint.session.authorized: return redirect(url_for('login')) @@ -225,7 +226,7 @@ def home(): else: session['gravatar'] = utils.avatar(account_info_json['sub'], 26) - return render_template('portfolio.html', templates=templates) + return render_template('portfolio.html', templates=templates, parent=None) else: flash("Error getting User info: \n" + account_info.text, 'error') return render_template('home.html', oidc_name=settings.oidcName) @@ -592,6 +593,7 @@ def infoutputs(infid=None): def configure(): selected_tosca = None inf_id = request.args.get('inf_id', None) + childs = request.args.get('childs', None) inputs = {} infra_name = "" @@ -635,7 +637,24 @@ def configure(): flash("InvalidTOSCA template name: %s" % selected_tosca, "error") return redirect(url_for('home')) - app.logger.debug("Template: " + json.dumps(toscaInfo[selected_tosca])) + child_templates = {} + selected_template = copy.deepcopy(toscaInfo[selected_tosca]) + if "childs" in toscaInfo[selected_tosca]["metadata"]: + if childs: + for child in childs.split(","): + if child in toscaInfo: + child_templates[child] = toscaInfo[child] + if "inputs" in toscaInfo[child]: + selected_template["inputs"].update(toscaInfo[child]["inputs"]) + if "tabs" in toscaInfo[child]: + selected_template["tabs"].extend(toscaInfo[child]["tabs"]) + else: + for child in toscaInfo[selected_tosca]["metadata"]["childs"]: + if child in toscaInfo: + child_templates[child] = toscaInfo[child] + return render_template('portfolio.html', templates=child_templates, parent=selected_tosca) + else: + app.logger.debug("Template: " + json.dumps(toscaInfo[selected_tosca])) try: creds = cred.get_creds(get_cred_id(), 1) @@ -645,10 +664,10 @@ def configure(): utils.get_project_ids(creds) return render_template('createdep.html', - template=toscaInfo[selected_tosca], - selectedTemplate=selected_tosca, - creds=creds, input_values=inputs, - infra_name=infra_name) + template=selected_template, + selectedTemplate=selected_tosca, + creds=creds, input_values=inputs, + infra_name=infra_name, child_templates=child_templates) @app.route('/vos') def getvos(): @@ -824,6 +843,14 @@ def add_ssh_keys_to_template(template): return template + def _merge_templates(template, new_template): + for item in ["inputs", "node_templates", "outputs"]: + if item in new_template["topology_template"]: + if item not in template["topology_template"]: + template["topology_template"][item] = {} + template["topology_template"][item].update(new_template["topology_template"][item]) + return template + @app.route('/submit', methods=['POST']) @authorized_with_valid_token def createdep(): @@ -832,6 +859,9 @@ def createdep(): app.logger.debug("Form data: " + json.dumps(request.form.to_dict())) + childs = [] + if 'extra_opts.childs' in form_data: + childs = form_data['extra_opts.childs'].split(",") cred_id = form_data['extra_opts.selectedCred'] cred_data = cred.get_cred(cred_id, get_cred_id()) access_token = oidc_blueprint.session.token['access_token'] @@ -870,10 +900,15 @@ def createdep(): with io.open(settings.toscaDir + request.args.get('template')) as stream: template = yaml.full_load(stream) + + for child in childs: + with io.open(settings.toscaDir + child) as stream: + template = _merge_templates(template, yaml.full_load(stream)) if 'metadata' not in template: template['metadata'] = {} template['metadata']['filename'] = request.args.get('template') + template['metadata']['childs'] = childs if priv_network_id and pub_network_id: template = add_network_id_to_template(template, priv_network_id, pub_network_id) diff --git a/app/templates/createdep.html b/app/templates/createdep.html index 69e66a504..7166e49bb 100644 --- a/app/templates/createdep.html +++ b/app/templates/createdep.html @@ -24,10 +24,23 @@

{% if 'metadata' in template and 'web' in template['metadata'] and template['metadata']['web'] %} ({{template['metadata']['web']}}) {% endif %} + {% if child_templates %} +
AddOns: + {% for name, child_template in child_templates.items() %} + {% if 'metadata' in child_template and 'name' in child_template['metadata'] and child_template['metadata']['name'] %} + {{ child_template['metadata']['name'] }}, + {% else %} + {{ name }}, + {% endif %} + {% endfor %} + {% endif %}
+ {% if child_templates %} + + {% endif %}
diff --git a/app/templates/portfolio.html b/app/templates/portfolio.html index 598c1648a..596b31c00 100644 --- a/app/templates/portfolio.html +++ b/app/templates/portfolio.html @@ -2,6 +2,25 @@ {% block title %}Portfolio{% endblock %} {% block content %} + +
{% include 'flashed_messages.html' %}
@@ -10,6 +29,13 @@
+ {% if parent %} +
+
+ Select AddOns: +
+
+ {% endif %}
@@ -18,7 +44,7 @@
{% endif %} -
+
{% if tosca['metadata']['display_name'] is defined %}{{tosca['metadata']['display_name']}}{% else %}{{tosca_filename}}{% endif %} @@ -46,7 +72,11 @@

{{tosca['description']}}

Read More + {% if parent %} + Add + {% else %} Configure + {% endif %}
{% if loop.index % 3 == 0 %} @@ -57,7 +87,12 @@
{% endif %} +
+ {% if parent %} +
diff --git a/app/templates/portfolio.html b/app/templates/portfolio.html index 596b31c00..32a5b1cf1 100644 --- a/app/templates/portfolio.html +++ b/app/templates/portfolio.html @@ -7,7 +7,8 @@ function AddChild(link, template) { if (selected_templates.includes(template)) { document.getElementById(template).classList.remove("bg-success"); - selected_templates.pop(template); + pos = selected_templates.indexOf(template); + selected_templates.splice(pos, 1) link.innerHTML = "Add"; link.classList.remove("badge-danger"); link.classList.add("badge-primary"); @@ -90,8 +91,9 @@
{% if parent %} -