EOX GitLab Instance

Commit abc79c97 authored by Nikola Jankovic's avatar Nikola Jankovic 💻
Browse files

added ingress

updated values
parent 3d61713d
Pipeline #18084 passed with stages
in 5 minutes and 52 seconds
{{- $fullName := include "vs-cache.fullname" . -}}
{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion -}}
apiVersion: networking.k8s.io/v1
{{- else -}}
apiVersion: extensions/v1beta1
{{- end }}
kind: Ingress
metadata:
name: {{ $fullName }}
labels:
{{- include "vs-cache.labels" . | nindent 4 }}
{{- with .Values.global.ingress.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
nginx.ingress.kubernetes.io/rewrite-target: /$1
{{- end }}
spec:
{{- if .Values.global.ingress.tls }}
tls:
{{- range .Values.global.ingress.tls }}
- hosts:
{{- range .hosts }}
- {{ . | quote }}
{{- end }}
secretName: {{ .secretName }}
{{- end }}
{{- end }}
rules:
{{- range .Values.global.ingress.hosts }}
{{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
- host: {{ .host | quote }}
http:
paths:
- path: /cache/(.*)
pathType: Prefix
backend:
service:
name: {{ $fullName }}
port:
number: 80
{{- else }}
- host: {{ .host | quote }}
http:
paths:
- path: /cache/(.*)
backend:
serviceName: {{ $fullName }}
servicePort: http
{{- end -}}
{{- end }}
replicaCount: 1
nameOverride:
fullNameOverride:
image:
repository: registry.gitlab.eox.at/vs/cache
......@@ -71,3 +73,18 @@ global:
storage:
cache: {}
layers: []
ingress:
enabled: true
annotations:
kubernetes.io/ingress.class: nginx
kubernetes.io/tls-acme: "true"
nginx.ingress.kubernetes.io/proxy-read-timeout: "600"
nginx.ingress.kubernetes.io/enable-cors: "true"
cert-manager.io/cluster-issuer: letsencrypt
hosts:
- host: vs.local
tls:
- hosts:
- vs.local
secretName: vs-secret
# hosts and tls will be redefined always
......@@ -109,4 +109,4 @@ fi
# create a database view for the mapcache items
echo "Creating database view for mapcache items"
psql "host=${DB_HOST} user=${DB_USER} password=${DB_PW} dbname=${DB_NAME} port=${DB_PORT}" -f /mapcache_items_view.sql
psql "host=${DB_HOST} user=${DB_USER} password=${DB_PW} dbname=${DB_NAME} port=${DB_PORT}" -f /opt/cache/mapcache_items_view.sql
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment