Merge pull request #32 from wojiushixiaobai/main

fix: 修复错误
This commit is contained in:
吴小白 2021-11-22 09:10:22 +08:00 committed by GitHub
commit c60543f23b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 34 deletions

View File

@ -1,29 +0,0 @@
{{- if .Values.koko.enabled }}
{{- with .Values.koko }}
{{- $fullName := printf "%s-%s" (include "jumpserver.fullname" $) "jms-koko-web" }}
apiVersion: v1
kind: Service
metadata:
name: {{ $fullName }}
labels:
{{- include "jumpserver.labels" $ | nindent 4 }}
{{- toYaml .labels | nindent 4 }}
annotations:
{{- toYaml .service.annotations | nindent 4 }}
spec:
type: {{ .service.web.type }}
ports:
- port: {{ .service.web.port }}
targetPort: web
protocol: TCP
name: web
sessionAffinity: ClientIP
sessionAffinityConfig:
clientIP:
timeoutSeconds: 10800
selector:
app.kubernetes.io/name: {{ include "jumpserver.name" $ }}
app.kubernetes.io/instance: {{ $.Release.Name }}
{{- toYaml .labels | nindent 4 }}
{{- end }}
{{- end }}

View File

@ -1,6 +1,6 @@
{{- if .Values.koko.enabled }} {{- if .Values.koko.enabled }}
{{- with .Values.koko }} {{- with .Values.koko }}
{{- $fullName := printf "%s-%s" (include "jumpserver.fullname" $) "jms-koko-ssh" }} {{- $fullName := printf "%s-%s" (include "jumpserver.fullname" $) "jms-koko" }}
apiVersion: v1 apiVersion: v1
kind: Service kind: Service
metadata: metadata:
@ -11,8 +11,12 @@ metadata:
annotations: annotations:
{{- toYaml .service.annotations | nindent 4 }} {{- toYaml .service.annotations | nindent 4 }}
spec: spec:
type: {{ .service.ssh.type }} type: {{ .service.type }}
ports: ports:
- port: {{ .service.web.port }}
targetPort: web
protocol: TCP
name: web
- port: {{ .service.ssh.port }} - port: {{ .service.ssh.port }}
targetPort: ssh targetPort: ssh
protocol: TCP protocol: TCP

View File

@ -202,12 +202,10 @@ koko:
# runAsUser: 1000 # runAsUser: 1000
service: service:
web:
type: ClusterIP type: ClusterIP
web:
port: 5000 port: 5000
ssh: ssh:
type: ClusterIP
# loadBalancerIP:
port: 2222 port: 2222
resources: {} resources: {}