Skip to content

Commit a08d1a0

Browse files
author
wlanboy
committed
Moved to emty dir, added configmap
1 parent e3da498 commit a08d1a0

File tree

6 files changed

+44
-28
lines changed

6 files changed

+44
-28
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
apiVersion: v1
2+
kind: ConfigMap
3+
metadata:
4+
name: {{ .Values.deploymentName }}-config
5+
data:
6+
application.properties: |
7+
# Endpoints
8+
management.endpoints.web.exposure.include=prometheus,health,info,metric
9+
management.endpoint.health.show-details=always
10+
# Buildinfo
11+
spring.config.import=classpath:META-INF/build-info.properties
12+
# Tracing
13+
spring.sleuth.propagation.type=w3c,b3

javahttpclient-chart/templates/deployment.yaml

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,26 @@ spec:
2020
ports:
2121
- containerPort: {{ .Values.service.targetPort }}
2222
volumeMounts:
23+
- name: config-volume
24+
mountPath: /app/application.properties
25+
subPath: application.properties
2326
- name: tmp-volume
24-
mountPath: {{ .Values.volume.mountPath }}
27+
mountPath: /tmp
28+
livenessProbe:
29+
httpGet:
30+
path: /actuator/health/liveness
31+
port: {{ .Values.service.targetPort }}
32+
initialDelaySeconds: 10
33+
periodSeconds: 10
34+
readinessProbe:
35+
httpGet:
36+
path: /actuator/health/readiness
37+
port: {{ .Values.service.targetPort }}
38+
initialDelaySeconds: 5
39+
periodSeconds: 10
2540
volumes:
41+
- name: config-volume
42+
configMap:
43+
name: {{ .Values.deploymentName }}-config
2644
- name: tmp-volume
27-
persistentVolumeClaim:
28-
claimName: {{ .Values.pvc.name }}
45+
emptyDir: {}

javahttpclient-chart/templates/gateway.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@ spec:
1111
name: https
1212
protocol: HTTPS
1313
hosts:
14-
- {{ .Values.istio.host }}
14+
{{- range .Values.hosts }}
15+
- {{ . }}
16+
{{- end }}
1517
tls:
1618
mode: SIMPLE
1719
credentialName: {{ .Values.istio.tls.secretName }}

javahttpclient-chart/templates/pvc.yaml

Lines changed: 0 additions & 14 deletions
This file was deleted.

javahttpclient-chart/templates/virtualservice.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@ metadata:
44
name: {{ .Values.deploymentname }}-vs
55
spec:
66
hosts:
7-
- {{ .Values.istio.host }}
7+
{{- range .Values.hosts }}
8+
- {{ . }}
9+
{{- end }}
810
exportTo:
911
- "."
1012
- istio-ingress

javahttpclient-chart/values.yaml

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,16 @@ service:
1313
port: 8080
1414
targetPort: 8080
1515

16-
pvc:
17-
enabled: true
18-
name: javahttpclient-tmp-pvc
19-
accessModes:
20-
- ReadWriteOnce
21-
storageClassName: ""
22-
size: "100Mi"
23-
2416
volume:
2517
mountPath: /tmp
2618

19+
hosts:
20+
- javahttpclient.tp.lan
21+
- javahttpclient.gmk.lan
22+
2723
istio:
2824
gatewayName: javahttpclient-gw
2925
gatewayNamespace: "istio-ingress"
30-
host: javahttpclient.tp.lan
3126
tls:
3227
enabled: true
3328
secretName: javahttpclient-tls
@@ -39,3 +34,4 @@ certManager:
3934
name: "local-ca-issuer"
4035
dnsNames:
4136
- javahttpclient.tp.lan
37+
- javahttpclient.gmk.lan

0 commit comments

Comments
 (0)