Skip to content

Commit

Permalink
fix mysql endpoint, secrets, doubling of cosv service (#2984)
Browse files Browse the repository at this point in the history
* fix mysql endpoint, secrets, doubling of cosv service
* fix neo4j volumes data mode
  • Loading branch information
icemachined authored Nov 8, 2024
1 parent 877c276 commit 8fe8813
Show file tree
Hide file tree
Showing 4 changed files with 70 additions and 16 deletions.
11 changes: 0 additions & 11 deletions save-cloud-charts/save-cloud/templates/agent.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,6 @@ metadata:
#agent services
apiVersion: v1
kind: Service
metadata:
name: {{ .Values.backend_cosv.name }}
namespace: {{ .Values.agentNamespace }}
spec:
type: ExternalName
externalName: {{ .Values.backend_cosv.name }}.{{ .Values.namespace }}.svc.cluster.local
ports:
- port: {{ .Values.backend_cosv.containerPort }}
---
apiVersion: v1
kind: Service
metadata:
name: {{ .Values.backend.name }}
namespace: {{ .Values.agentNamespace }}
Expand Down
6 changes: 3 additions & 3 deletions save-cloud-charts/save-cloud/templates/gateway.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,16 +55,16 @@ spec:
- mountPath: /home/cnb/cacerts
name: cacerts
- mountPath: /security
name: his-certs
name: ca-certs
{{ end }}
volumes:
- {{ include "spring-boot.config-volume" (dict "service" .Values.gateway) | indent 10 | trim }}
- name: oauth-credentials
secret:
secretName: oauth-credentials
- name: his-certs
- name: ca-certs
secret:
secretName: his-certs
secretName: ca-certs
- name: cacerts
emptyDir: {}
---
Expand Down
52 changes: 52 additions & 0 deletions save-cloud-charts/save-cloud/templates/mysql-service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{{- if .Values.mysql.external -}}
apiVersion: v1
kind: Endpoints
metadata:
name: mysql-service
subsets:
- addresses:
- ip: {{ .Values.mysql.ip }}
ports:
- port: 3306

---

apiVersion: v1
kind: Service
metadata:
name: mysql-service
spec:
ports:
- port: 3306
targetPort: 3306
protocol: TCP
selector: {}
type: ClusterIP

{{- else }}

apiVersion: v1
kind: Service
metadata:
name: mysql-service
spec:
ports:
- port: 3306
selector:
io.kompose.service: mysql
clusterIP: None

---

apiVersion: v1
kind: Service
metadata:
name: mysql-service-lb
spec:
ports:
- port: 3306
selector:
io.kompose.service: mysql
type: LoadBalancer

{{- end }}
17 changes: 15 additions & 2 deletions save-cloud-charts/save-cloud/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -201,9 +201,22 @@ neo4j:
memory: "2Gi"
volumes:
data:
mode: selector
selector:
# REQUIRED: specify a volume mode to use for data
# Valid values are share|selector|defaultStorageClass|volume|volumeClaimTemplate|dynamic
# To get up-and-running quickly, for development or testing, use "defaultStorageClass" for a dynamically provisioned volume of the default storage class.
mode: "volume"

# Only used if mode is set to "volume"
# Provide an explicit volume to use
volume:
# If set an init container (running as root) will be added that runs:
# `chown -R <securityContext.fsUser>:<securityContext.fsGroup>` AND `chmod -R g+rwx`
# on the volume. This is useful for some filesystems (e.g. NFS) where Kubernetes fsUser or fsGroup settings are not respected
setOwnerAndGroupWritableFilePermissions: false

# Example (using a specific Persistent Volume Claim)
persistentVolumeClaim:
claimName: data-neo4j-0
demo_cpg:
name: demo-cpg
profile: dev
Expand Down

0 comments on commit 8fe8813

Please sign in to comment.