Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
ukff committed Oct 3, 2024
1 parent 796f402 commit 2c24b09
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 15 deletions.
33 changes: 19 additions & 14 deletions resources/keb/templates/globalaccounts.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,29 +2,34 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: "kyma-environment-globalaccounts"
name: "{{- .Values.globalaccounts.name -}}"
namespace: kcp-system
labels:
app.kubernetes.io/name: kyma-environment-globalaccounts
name: "{{- .Values.globalaccounts.name -}}"
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: kyma-environment-globalaccounts
name: "{{- .Values.globalaccounts.name -}}"
template:
metadata:
name: kyma-environment-globalaccounts
name: "{{- .Values.globalaccounts.name -}}"
labels:
app.kubernetes.io/name: kyma-environment-globalaccounts
app.kubernetes.io/name: "{{- .Values.globalaccounts.name -}}"
spec:
serviceAccountName: kcp-kyma-environment-broker
serviceAccountName: {{ .Values.global.kyma_environment_broker.serviceAccountName }}
{{- with .Values.deployment.securityContext }}
securityContext:
runAsUser: 2000
restartPolicy: Always
{{ toYaml . | nindent 12 }}
{{- end }}
{{- if ne .Values.imagePullSecret "" }}
imagePullSecrets:
- name: {{ .Values.imagePullSecret }}
{{- end }}
containers:
- name: kyma-environment-globalaccounts
- name: "{{- .Values.globalaccounts.name -}}"
command: ["/bin/main"]
image: europe-docker.pkg.dev/kyma-project/prod/kyma-environment-globalaccounts:1.0.0
image: "{{ .Values.global.images.container_registry.path }}/{{ .Values.global.images.kyma_environment_broker.dir }}{{ .Values.globalaccounts.name -}}:{{ .Values.global.images.kyma_environment_globalaccounts.version }}"
imagePullPolicy: Always
env:
- name: GLOBALACCOUNTS_DATABASE_SECRET_KEY
Expand Down Expand Up @@ -61,17 +66,17 @@ spec:
- name: GLOBALACCOUNTS_CIS_ACCOUNTS_CLIENT_ID
valueFrom:
secretKeyRef:
name: {{ .Values.cis.accounts.secretName | required "please specify .Values.cis.accounts.secretName" | quote }}
name: {{ .Values.globalaccounts.accounts.clientId | required "please specify .Values.globalaccounts.accounts.clientId" | quote }}
key: id
- name: GLOBALACCOUNTS_CIS_ACCOUNTS_CLIENT_SECRET
valueFrom:
secretKeyRef:
name: {{ .Values.cis.accounts.secretName | required "please specify .Values.cis.accounts.secretName" | quote }}
name: {{ .Values.globalaccounts.accounts.secretName | required "please specify .Values.globalaccounts.accounts.secretName" | quote }}
key: secret
- name: GLOBALACCOUNTS_ACCOUNTS_AUTH_URL
value: {{ .Values.cis.accounts.authURL | required "please specify .Values.cis.accounts.authURL" | quote }}
value: {{ .Values.globalaccounts.accounts.authURL | required "please specify .Values.globalaccounts.accounts.authURL" | quote }}
- name: GLOBALACCOUNTS_ACCOUNTS_SERVICE_URL
value: {{ .Values.cis.accounts.serviceURL | required "please specify .Values.cis.accounts.serviceURL" | quote }}
value: {{ .Values.globalaccounts.accounts.serviceURL | required "please specify .Values.globalaccounts.accounts.serviceURL" | quote }}
- name: GLOBALACCOUNTS_DATABASE_SSLMODE
valueFrom:
secretKeyRef:
Expand Down
11 changes: 10 additions & 1 deletion resources/keb/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ global:
kyma_environment_subaccount_sync:
dir:
version: "1.10.12"
kyma_environment_globalaccounts:
dir:
version: "1.10.12"
kyma_environment_broker:
enabled: false
serviceAccountName: "kcp-kyma-environment-broker"
Expand Down Expand Up @@ -605,4 +608,10 @@ testConfig:

globalaccounts:
enabled: false
dryRun: true
dryRun: true
name: "kyma-environment-globalaccounts"
accounts:
secretName: ""
clientId: ""
authURL: ""
serviceURL: ""

0 comments on commit 2c24b09

Please sign in to comment.