Skip to content

Commit f36c981

Browse files
authored
43 add support ckan (#44)
* add: required data catalog * add: config requiredb by ui * add: data server s3 * fix: ct config * release: 3.3.0
1 parent b0b5686 commit f36c981

File tree

8 files changed

+194
-122
lines changed

8 files changed

+194
-122
lines changed

charts/mint/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ type: application
1515
# This is the chart version. This version number should be incremented each time you make changes
1616
# to the chart and its templates, including the app version.
1717
# Versions are expected to follow Semantic Versioning (https://semver.org/)
18-
version: 3.2.0
18+
version: 3.3.0
1919
# This is the version number of the application being deployed. This version number should be
2020
# incremented each time you make changes to the application. Versions are not expected to
2121
# follow Semantic Versioning. They should reflect the version the application is using.

charts/mint/templates/ensemble-manager-config.yaml

Lines changed: 32 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,40 @@ data:
4848
{{- end }}
4949
5050
51-
{{- with .Values.components.ensemble_manager }}
52-
{{- if .execution_engine.type }}
53-
"execution_engine": {{ .execution_engine.type | quote }},
54-
"{{ .execution_engine.type }}":
55-
{{ .execution_engine.config | toRawJson | nindent 12}},
51+
{{- with .Values.components.ensemble_manager.config }}
52+
{{- if .type }}
53+
"execution_engine": {{ .type | quote }},
54+
"{{ .type }}":
55+
{{ .execution_engine | toRawJson | nindent 12}},
5656
{{- end }}
5757
{{- end }}
58+
59+
60+
{{- with .Values.components.ensemble_manager.config }}
61+
{{- if eq .data_catalog.type "CKAN"}}
62+
"data_catalog_api": {{ .data_catalog.api | quote }},
63+
"data_catalog_type": {{ .data_catalog.type | quote }},
64+
"data_catalog_extra": {
65+
"owner_organization_id": {{ .data_catalog.extra.owner_organization_id | quote }},
66+
"owner_provenance_id": {{ .data_catalog.extra.owner_provenance_id | quote }}
67+
},
68+
{{- end}}
69+
{{- end}}
70+
71+
72+
73+
{{- if eq .Values.components.ensemble_manager.config.data_server.type "S3" }}
74+
{{- with .Values.components.ensemble_manager.config }}
75+
"data_server_type": {{ .data_server.type | quote }},
76+
"data_server": {
77+
"region": {{ .data_server.region | quote }},
78+
"bucket": {{ .data_server.bucket | quote }},
79+
{{- end}}
80+
"access_key": {{ .Values.secrets.data_server.s3.access_key | quote }},
81+
"secret_access_key": {{ .Values.secrets.data_server.s3.secret_key | quote }}
82+
},
83+
{{- end}}
84+
5885
"auth_server": {{ .Values.auth.url | quote }},
5986
"auth_realm": {{ .Values.auth.realm | quote }},
6087
"auth_client_id": {{ .Values.auth.ui_client_id | quote }},

charts/mint/templates/ui-config.yaml

Lines changed: 28 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -38,35 +38,35 @@ data:
3838
{{ if .enabled }}
3939
window.REACT_APP_ENSEMBLE_MANAGER_API = "http{{ if .ingress.tls }}s{{ end }}://{{ with (first .ingress.hosts ) }}{{ .host }}{{ end }}/{{ .api_version }}";
4040
//Execution - Local
41-
window.REACT_APP_EXECUTION_ENGINE = "{{ .execution_engine.type }}";
41+
window.REACT_APP_EXECUTION_ENGINE = "{{ .config.type }}";
4242
43-
{{ if eq .execution_engine.type "localex" }}
44-
window.REACT_APP_LOCALEX_CODEDIR = "{{ .execution_engine.config.data_dir }}/code";
45-
window.REACT_APP_LOCALEX_DATADIR = "{{ .execution_engine.config.data_dir }}/data";
46-
window.REACT_APP_LOCALEX_TEMPDIR = "{{ .execution_engine.config.data_dir }}/temp";
47-
window.REACT_APP_LOCALEX_LOGDIR = "{{ .execution_engine.config.data_dir }}/logs";
48-
window.REACT_APP_LOCALEX_DATAURL = "{{ .execution_engine.config.data_url }}/data";
49-
window.REACT_APP_LOCALEX_LOGURL = "{{ .execution_engine.config.data_url }}/logs";
50-
window.REACT_APP_LOCALEX_PARALLEL = "{{ .execution_engine.config.parallel }}";
43+
{{ if eq .config.type "localex" }}
44+
window.REACT_APP_LOCALEX_CODEDIR = "{{ .config.data_dir }}/code";
45+
window.REACT_APP_LOCALEX_DATADIR = "{{ .config.data_dir }}/data";
46+
window.REACT_APP_LOCALEX_TEMPDIR = "{{ .config.data_dir }}/temp";
47+
window.REACT_APP_LOCALEX_LOGDIR = "{{ .config.data_dir }}/logs";
48+
window.REACT_APP_LOCALEX_DATAURL = "{{ .config.data_url }}/data";
49+
window.REACT_APP_LOCALEX_LOGURL = "{{ .config.data_url }}/logs";
50+
window.REACT_APP_LOCALEX_PARALLEL = "{{ .config.parallel }}";
5151
{{ end }}
5252
53-
{{ if eq .execution_engine.type "tapis" }}
54-
window.REACT_APP_LOCALEX_CODEDIR = "{{ .execution_engine.config.data_dir }}/code";
55-
window.REACT_APP_LOCALEX_DATADIR = "{{ .execution_engine.config.data_dir }}/data";
56-
window.REACT_APP_LOCALEX_TEMPDIR = "{{ .execution_engine.config.data_dir }}/temp";
57-
window.REACT_APP_LOCALEX_LOGDIR = "{{ .execution_engine.config.data_dir }}/logs";
58-
window.REACT_APP_LOCALEX_DATAURL = "{{ .execution_engine.config.data_url }}/data";
59-
window.REACT_APP_LOCALEX_LOGURL = "{{ .execution_engine.config.data_url }}/logs";
60-
window.REACT_APP_LOCALEX_PARALLEL = "{{ .execution_engine.config.parallel }}";
53+
{{ if eq .config.type "tapis" }}
54+
window.REACT_APP_LOCALEX_CODEDIR = "{{ .config.data_dir }}/code";
55+
window.REACT_APP_LOCALEX_DATADIR = "{{ .config.data_dir }}/data";
56+
window.REACT_APP_LOCALEX_TEMPDIR = "{{ .config.data_dir }}/temp";
57+
window.REACT_APP_LOCALEX_LOGDIR = "{{ .config.data_dir }}/logs";
58+
window.REACT_APP_LOCALEX_DATAURL = "{{ .config.data_url }}/data";
59+
window.REACT_APP_LOCALEX_LOGURL = "{{ .config.data_url }}/logs";
60+
window.REACT_APP_LOCALEX_PARALLEL = "{{ .config.parallelism }}";
6161
{{ end }}
6262
6363
64-
{{ if eq .execution_engine.type "wings" }}
64+
{{ if eq .config.type "wings" }}
6565
//Execution - Wings
66-
window.REACT_APP_WINGS_EXPORT_URL = "{{ .execution_engine.config.wings_export_url }}";
67-
window.REACT_APP_WINGS_STORAGE = "{{ .execution_engine.config.wings_storage }}";
68-
window.REACT_APP_WINGS_DOTPATH = "{{ .execution_engine.config.wings_dot_path }}";
69-
window.REACT_APP_WINGS_ONTURL = "{{ .execution_engine.config.wings_ont_url }}";
66+
window.REACT_APP_WINGS_EXPORT_URL = "{{ .config.wings_export_url }}";
67+
window.REACT_APP_WINGS_STORAGE = "{{ .config.wings_storage }}";
68+
window.REACT_APP_WINGS_DOTPATH = "{{ .config.wings_dot_path }}";
69+
window.REACT_APP_WINGS_ONTURL = "{{ .config.wings_ont_url }}";
7070
{{ end }}
7171
7272
{{ end }}
@@ -87,4 +87,10 @@ data:
8787
window.REACT_APP_INGESTION_API = "http://node1.ingestion.mint.isi.edu/v1.3.0";
8888
window.REACT_APP_AIRFLOW_API = "https://airflow.mint.isi.edu/api/v1";
8989
window.REACT_APP_AIRFLOW_DAG_DOWNLOAD_THREAD_ID = "download_thread"
90+
91+
{{ if and .Values.components.ensemble_manager.config.data_catalog (eq .Values.components.ensemble_manager.config.data_catalog.type "CKAN") }}
92+
window.REACT_APP_DATA_CATALOG_TYPE = "CKAN";
93+
window.REACT_APP_DATA_CATALOG_KEY = {{ .Values.secrets.data_catalog.ckan.api_key | quote }};
94+
{{ end }}
95+
9096
{{- end}}

charts/mint/values.yaml

Lines changed: 36 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -263,17 +263,33 @@ components:
263263
serviceAccountName: default
264264
environment:
265265
data_dir: /var/mint
266-
data_url: http://localhost:30010/data
267-
parallel: 1
268-
execution_engine:
269-
type: localex
270-
config:
271-
codedir: /home/node/app/data/code
272-
datadir: /home/node/app/data/data
273-
tempdir: /home/node/app/data/temp
274-
logdir: /home/node/app/data/logs
275-
dataurl: http://localhost:30010/data
276-
parallelism: 1
266+
config:
267+
data_catalog:
268+
api: "http://localhost:5000"
269+
type: "CKAN"
270+
extra:
271+
owner_organization_id: "21033e7d-484d-4974-9340-8c5755242c1f"
272+
owner_provenance_id: "9ef60317-5da5-4050-8bbc-7d6826fee49f"
273+
data_server:
274+
type: "S3"
275+
region: "ap-south-1"
276+
bucket: "mintdata"
277+
278+
graphql:
279+
endpoint: "localhost:30003/v1/graphql"
280+
enable_ssl: false
281+
use_secret: true
282+
283+
execution_engine:
284+
type: "localex"
285+
code_dir: "/home/node/app/data/code"
286+
data_dir: "/home/node/app/data/data"
287+
temp_dir: "/home/node/app/data/temp"
288+
log_dir: "/home/node/app/data/logs"
289+
data_url: "s3://mintdata"
290+
log_url: "s3://mintdata"
291+
parallelism: 2
292+
277293
ingress:
278294
enabled: true
279295
className: ""
@@ -293,10 +309,19 @@ components:
293309
selector: {}
294310
annotations:
295311
helm.sh/resource-policy: keep
312+
296313
google:
297314
maps:
298315
key: AIzaSyAkRnERo4F4dy9AhdrWHAN5vdJWs0vZCgM
316+
299317
secrets:
318+
data_catalog:
319+
ckan:
320+
api_key: CHANGEME
321+
data_server:
322+
s3:
323+
access_key: CHANGEME
324+
secret_key: CHANGEME
300325
database:
301326
data_catalog:
302327
username: datacatalog

ct-arm-64.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
remote: origin
22
target-branch: main
33
chart-dirs:
4-
- charts/mint
4+
- charts
55
helm-extra-args: --timeout 600s
66
helm-extra-set-args: --set=arm_support=true --set components.data_catalog.enabled=false

ct.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
remote: origin
22
target-branch: main
33
chart-dirs:
4-
- charts/mint
4+
- charts
55
helm-extra-args: --timeout 600s
66
#helm-extra-set-args: --set=arm_support=true --set components.data_catalog.enabled=false

0 commit comments

Comments
 (0)