blob: 8d519f645f4eda802f736412d18886f68d5f1871 [file] [log] [blame]
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# mysql services
---
apiVersion: v1
kind: Service
metadata:
name: {{ include "devlake.fullname" . }}-mysql
labels:
{{- include "devlake.labels" . | nindent 4 }}
spec:
selector:
{{- include "devlake.selectorLabels" . | nindent 4 }}
devlakeComponent: mysql
ports:
- protocol: TCP
name: mysql
port: 3306
targetPort: 3306
# grafana services
---
apiVersion: v1
kind: Service
metadata:
name: {{ include "devlake.fullname" . }}-grafana
labels:
{{- include "devlake.labels" . | nindent 4 }}
spec:
type: {{ .Values.service.type }}
selector:
{{- include "devlake.selectorLabels" . | nindent 4 }}
devlakeComponent: grafana
ports:
- protocol: TCP
name: grafana
port: {{ .Values.service.grafanaPort }}
targetPort: 3000
{{- if eq .Values.service.type "NodePort" }}
nodePort: {{ .Values.service.grafanaPort }}
{{- end }}
# devlake services
---
apiVersion: v1
kind: Service
metadata:
name: {{ include "devlake.fullname" . }}-lake
labels:
{{- include "devlake.labels" . | nindent 4 }}
spec:
selector:
{{- include "devlake.selectorLabels" . | nindent 4 }}
devlakeComponent: lake
ports:
- protocol: TCP
name: devlake
port: 8080
targetPort: 8080
---
# ui
apiVersion: v1
kind: Service
metadata:
name: {{ include "devlake.fullname" . }}-ui
labels:
{{- include "devlake.labels" . | nindent 4 }}
spec:
type: {{ .Values.service.type }}
selector:
{{- include "devlake.selectorLabels" . | nindent 4 }}
devlakeComponent: ui
ports:
- protocol: TCP
name: ui
port: {{ .Values.service.uiPort }}
targetPort: 4000
{{- if eq .Values.service.type "NodePort" }}
nodePort: {{ .Values.service.uiPort }}
{{- end }}