From fa6e9ea3b744dbd6b9260b6bd241438b54e60034 Mon Sep 17 00:00:00 2001 From: Danny Bessems Date: Fri, 7 Jul 2023 17:10:29 +0200 Subject: [PATCH] fix: Override default webpage --- charts/json-server/Chart.yaml | 4 +- charts/json-server/templates/configmap.yaml | 50 ++++++++++++++++++++ charts/json-server/templates/deployment.yaml | 3 ++ 3 files changed, 55 insertions(+), 2 deletions(-) diff --git a/charts/json-server/Chart.yaml b/charts/json-server/Chart.yaml index 9fffb5a..094ab82 100644 --- a/charts/json-server/Chart.yaml +++ b/charts/json-server/Chart.yaml @@ -6,10 +6,10 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: v0.5.1 +version: v0.5.2 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to # follow Semantic Versioning. They should reflect the version the application is using. # It is recommended to use it with quotes. -appVersion: "v0.5.1" +appVersion: "v0.5.2" diff --git a/charts/json-server/templates/configmap.yaml b/charts/json-server/templates/configmap.yaml index d2f770f..5d14bfb 100644 --- a/charts/json-server/templates/configmap.yaml +++ b/charts/json-server/templates/configmap.yaml @@ -4,6 +4,56 @@ kind: ConfigMap metadata: name: {{ .Release.Name }}-configmap data: + index.html: | + + + + + JSON Server + + + +
+
+ +
+
+
+
+

Congrats!

+

+ You're successfully running JSON Server +
+ ✧*。٩(ˊᗜˋ*)و✧*。 +

+ +
+ +
+
+ + + + + + db.json: | {{ include "common.tplvalues.render" ( dict "value" .Values.seedData.configInline "context" $) | indent 4 }} {{- end -}} diff --git a/charts/json-server/templates/deployment.yaml b/charts/json-server/templates/deployment.yaml index 25893bf..6364435 100644 --- a/charts/json-server/templates/deployment.yaml +++ b/charts/json-server/templates/deployment.yaml @@ -49,6 +49,9 @@ spec: - name: {{ .Release.Name }}-configmap mountPath: /data/db.json subPath: db.json + - name: {{ .Release.Name }}-configmap + mountPath: /usr/local/lib/node_modules/json-server/public/index.html + subPath: index.html volumes: - name: {{ .Release.Name }}-configmap configMap: