Merge pull request #1360 from FlipEnergy/helm_services

[Helm] add service type values and InitContainer to wait for Postgres
pull/1391/head
TheFrenchGhosty 4 years ago committed by GitHub
commit 651fd79325
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,7 +1,7 @@
apiVersion: v2 apiVersion: v2
name: invidious name: invidious
description: Invidious is an alternative front-end to YouTube description: Invidious is an alternative front-end to YouTube
version: 1.0.0 version: 1.1.0
appVersion: 0.20.1 appVersion: 0.20.1
keywords: keywords:
- youtube - youtube

@ -23,6 +23,13 @@ spec:
runAsUser: {{ .Values.securityContext.runAsUser }} runAsUser: {{ .Values.securityContext.runAsUser }}
runAsGroup: {{ .Values.securityContext.runAsGroup }} runAsGroup: {{ .Values.securityContext.runAsGroup }}
fsGroup: {{ .Values.securityContext.fsGroup }} fsGroup: {{ .Values.securityContext.fsGroup }}
initContainers:
- name: wait-for-postgresql
image: postgres
args:
- /bin/sh
- -c
- until pg_isready -h {{ .Values.config.db.host }} -p {{ .Values.config.db.port }} -U {{ .Values.config.db.user }}; do echo waiting for database; sleep 2; done;
containers: containers:
- name: {{ .Chart.Name }} - name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
@ -50,4 +57,5 @@ spec:
httpGet: httpGet:
port: 3000 port: 3000
path: / path: /
initialDelaySeconds: 15
restartPolicy: Always restartPolicy: Always

@ -7,10 +7,14 @@ metadata:
chart: {{ .Chart.Name }} chart: {{ .Chart.Name }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
spec: spec:
type: {{ .Values.service.type }}
ports: ports:
- name: http - name: http
port: 3000 port: {{ .Values.service.port }}
targetPort: 3000 targetPort: 3000
selector: selector:
app: {{ template "invidious.name" . }} app: {{ template "invidious.name" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
{{- if .Values.service.loadBalancerIP }}
loadBalancerIP: {{ .Values.service.loadBalancerIP }}
{{- end }}

@ -13,6 +13,11 @@ autoscaling:
maxReplicas: 16 maxReplicas: 16
targetCPUUtilizationPercentage: 50 targetCPUUtilizationPercentage: 50
service:
type: clusterIP
port: 3000
#loadBalancerIP:
resources: {} resources: {}
#requests: #requests:
# cpu: 100m # cpu: 100m

Loading…
Cancel
Save