ci: add go service to charts
This commit is contained in:
parent
2f22303de5
commit
b4c7a0386d
|
@ -61,6 +61,30 @@ spec:
|
|||
volumeMounts:
|
||||
{{- toYaml . | nindent 12 }}
|
||||
{{- end }}
|
||||
- name: {{ .Chart.Name }}-secondary
|
||||
ports:
|
||||
- name: secondary
|
||||
containerPort: 8000
|
||||
protocol: TCP
|
||||
image: "{{ .Values.secondaryApp.image.repository }}:{{ .Values.secondaryApp.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.secondaryApp.image.pullPolicy }}
|
||||
{{- with .Values.secondaryApp.securityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 12 }}
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
{{- if .Values.persistence.enabled }}
|
||||
- name: data
|
||||
mountPath: {{ .Values.persistence.mountPath }}
|
||||
{{- end }}
|
||||
{{- with .Values.secondaryApp.resources }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if .Values.secondaryApp.command }}
|
||||
command:
|
||||
{{- toYaml .Values.secondaryApp.command | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- with .Values.volumes }}
|
||||
volumes:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
|
|
18
chart/templates/pvc.yaml
Normal file
18
chart/templates/pvc.yaml
Normal file
|
@ -0,0 +1,18 @@
|
|||
# templates/pvc.yaml
|
||||
{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) }}
|
||||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: {{ include "common.names.fullname" . }}
|
||||
labels:
|
||||
{{- include "common.labels.standard" . | nindent 4 }}
|
||||
spec:
|
||||
accessModes:
|
||||
{{- toYaml .Values.persistence.accessModes | nindent 4 }}
|
||||
resources:
|
||||
requests:
|
||||
storage: {{ .Values.persistence.size }}
|
||||
{{- if .Values.persistence.storageClass }}
|
||||
storageClassName: {{ .Values.persistence.storageClass | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
|
@ -10,4 +10,7 @@ spec:
|
|||
targetPort: http
|
||||
protocol: TCP
|
||||
name: http
|
||||
- name: secondary
|
||||
port: 8000
|
||||
targetPort: 8000
|
||||
selector: {{- include "chart.selectorLabels" . | nindent 4 }}
|
||||
|
|
|
@ -112,21 +112,34 @@ autoscaling:
|
|||
targetCPUUtilizationPercentage: 80
|
||||
# targetMemoryUtilizationPercentage: 80
|
||||
|
||||
# Additional volumes on the output Deployment definition.
|
||||
volumes: []
|
||||
# - name: foo
|
||||
# secret:
|
||||
# secretName: mysecret
|
||||
# optional: false
|
||||
volumes:
|
||||
- name: data
|
||||
persistentVolumeClaim:
|
||||
claimName: blog-service-claim
|
||||
|
||||
# Additional volumeMounts on the output Deployment definition.
|
||||
volumeMounts: []
|
||||
# - name: foo
|
||||
# mountPath: "/etc/foo"
|
||||
# readOnly: true
|
||||
volumeMounts:
|
||||
- name: data
|
||||
mountPath: /data
|
||||
|
||||
secondaryApp:
|
||||
image:
|
||||
repository: registry.acayip.dev/blog-services
|
||||
tag: "latest"
|
||||
pullPolicy: IfNotPresent
|
||||
securityContext: {}
|
||||
resources: {}
|
||||
|
||||
nodeSelector: {}
|
||||
|
||||
tolerations: []
|
||||
|
||||
affinity: {}
|
||||
|
||||
persistence:
|
||||
enabled: true
|
||||
existingClaim: "" # Use existing PVC (optional)
|
||||
storageClass: ""
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
size: 1Gi
|
||||
mountPath: /data # Directory where SQLite file is stored
|
||||
|
|
Loading…
Reference in New Issue
Block a user