Skip to content

Commit

Permalink
Merge pull request #2489 from NCEAS/feature-2487-k8s-configjs-path
Browse files Browse the repository at this point in the history
Change initContainer code to manipulate path for config.js
  • Loading branch information
rushirajnenuji authored Jul 31, 2024
2 parents bcc2c7e + f9d94b4 commit 0c598ee
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 6 deletions.
3 changes: 3 additions & 0 deletions helm/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,9 @@ spec:
finish=$(date +%s);
echo "$FILENAME download and install took $((finish - start)) sec";
{{- end }}
sed -i \
's|"/config/config.js"|"{{ include "metacatui.clean.root" . }}/config/config.js"|g' \
"${DEST}"/index.html;
volumeMounts:
- name: {{ .Release.Name }}-mcui-source-files
mountPath: /metacatui
Expand Down
21 changes: 15 additions & 6 deletions helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ global:
## * * * IMPORTANT NOTE: * * * DO NOT SET THE FOLLOWING VALUES IN THIS SECTION! * * *
## They will be ignored here, because they are populated from the "global" section, above:
## * theme: uses '.Values.global.metacatUiThemeName'
## * root: uses '.Values.global.metacatUiWebRoot'
## * root: uses '.Values.global.metacatUiWebRoot'
## * baseUrl: uses '.Values.global.metacatExternalBaseUrl'
## * d1CNBaseUrl: uses base URL portion of '.Values.global.d1ClientCnUrl'
## * metacatContext: uses '.Values.global.metacatAppContext'
Expand All @@ -98,11 +98,14 @@ customTheme:
enabled: false

## @param customTheme.themeClaimName substitute your own PVC name
## Ignored unless customTheme is enabled
##
claimName: "Your-Pre-Configured-pvc-name"

## @param customTheme.subPath path to theme directory, within mounted filesystem
## For example, if you cloned https://github.com/NCEAS/metacatui-themes to the root of your
## Ignored unless customTheme is enabled
##
## Example: if you cloned https://github.com/NCEAS/metacatui-themes to the root of your
## shared drive, it would look like this:
##
## /metacatui-themes
Expand All @@ -123,7 +126,7 @@ customTheme:
## ...etc ├── ...etc
##
## ...so to use the drp theme, you would set the subPath to:
## subPath: "metacatui-themes/src/drp/js/themes/drp"
## subPath: "metacatui-themes/src/drp/js/themes/drp" # (do NOT include initial "/" in subPath)
##
subPath: ""

Expand Down Expand Up @@ -222,7 +225,10 @@ source:

## @param source.pvc Provide custom source files on a pre-configured PVC (typ. for development)
##
## Note these settings ignored unless 'source.from:' is set to 'pvc'
## Note:
## 1. these settings ignored unless 'source.from:' is set to 'pvc'
## 2. the value of 'var appConfigPath' in index.html must be set manually. (This value is
## autoconfigured for other 'source' scenarios).
##
pvc:
## @param volumes.name substitute your own PVC name
Expand All @@ -237,11 +243,14 @@ autoscaling:
maxReplicas: 100
targetCPUUtilizationPercentage: 80

image:
## NGINX image version to use. Setting a specific value is safer than using "LATEST"
## See dockerhub for versions: https://hub.docker.com/_/nginx
tag: 1.27.0

nodeSelector: {}
tolerations: []
affinity: {}

image: {}
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
Expand Down

0 comments on commit 0c598ee

Please sign in to comment.