Skip to content

Commit

Permalink
Add base path env (#84)
Browse files Browse the repository at this point in the history
Add support to the helm chart that the base path does not stop the deployment of Lab.
  • Loading branch information
antejavor authored Nov 29, 2024
1 parent bb43336 commit c5fe0d2
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 14 deletions.
4 changes: 2 additions & 2 deletions charts/memgraph-lab/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: memgraph-lab
home: https://memgraph.com/
type: application
# Chart version, should be incremented each time the chart changes, including appVersion.
version: 0.1.4
version: 0.1.5
# Version number of the docker image memgraph/lab.
# Use it with quotes.
appVersion: "2.18.1"
appVersion: "2.19.1"
description: Memgraph Lab Helm Chart
keywords:
- graph
Expand Down
2 changes: 2 additions & 0 deletions charts/memgraph-lab/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,5 +47,7 @@ env:
value: memgraph
- name: QUICK_CONNECT_MG_PORT
value: "7687"
- name: BASE_PATH
value: /
```
Refer to the [Memgraph Lab documentation](https://memgraph.com/docs/data-visualization) for details on how to connect to and interact with Memgraph.
11 changes: 11 additions & 0 deletions charts/memgraph-lab/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,14 @@ Create the name of the service account to use
{{- default "default" .Values.serviceAccount.name }}
{{- end }}
{{- end }}

{{/*
Get the base path env value
*/}}
{{- define "getBasePath" -}}
{{- range .Values.env }}
{{- if eq .name "BASE_PATH" }}
{{- .value }}
{{- end }}
{{- end }}
{{- end }}
4 changes: 2 additions & 2 deletions charts/memgraph-lab/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@ spec:
protocol: TCP
livenessProbe:
httpGet:
path: /check
path: {{ include "getBasePath" . }}/check
port: http
readinessProbe:
httpGet:
path: /check
path: {{ include "getBasePath" . }}/check
port: http
resources:
{{- toYaml .Values.resources | nindent 12 }}
Expand Down
20 changes: 10 additions & 10 deletions charts/memgraph-lab/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,20 +39,20 @@ serviceAccount:
# If not set and create is true, a name is generated using the fullname template
name: ""


imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""

# Supported env variables: https://memgraph.com/docs/data-visualization/install-and-connect#environment-variables
env:
- name: QUICK_CONNECT_MG_HOST
value: memgraph
- name: QUICK_CONNECT_MG_PORT
value: "7687"
- name: QUICK_CONNECT_MG_HOST
value: memgraph-db
- name: QUICK_CONNECT_MG_PORT
value: "7687"
- name: BASE_PATH
value: ""

podSecurityContext: {}
# fsGroup: 2000

securityContext: {}
# capabilities:
Expand All @@ -69,10 +69,10 @@ ingress:
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
hosts:
- host: chart-example.local
paths:
- path: /
pathType: ImplementationSpecific
- host: chart-example.local
paths:
- path: /
pathType: ImplementationSpecific
tls: []
# - secretName: chart-example-tls
# hosts:
Expand Down

0 comments on commit c5fe0d2

Please sign in to comment.