Skip to content

Commit

Permalink
Merge branch 'staging'
Browse files Browse the repository at this point in the history
  • Loading branch information
churnikov committed Dec 12, 2024
2 parents 8b24177 + e152255 commit 61f259b
Show file tree
Hide file tree
Showing 25 changed files with 11,774 additions and 10 deletions.
2 changes: 1 addition & 1 deletion apps/custom-app/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "0.1"
description: A Helm chart for a standard serve app
name: custom-app
version: 1.1.0
version: 1.1.1
maintainers:
- name: Team Whale
email: [email protected]
2 changes: 2 additions & 0 deletions apps/custom-app/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ metadata:
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}"
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host"
{{- end }}
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
spec:
rules:
- host: {{ .Release.Name }}.{{ .Values.global.domain }}
Expand Down
2 changes: 1 addition & 1 deletion apps/dash/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "0.1"
description: A Helm chart Dash apps
name: dash-app
version: 1.0.2
version: 1.0.3
maintainers:
- name: Team Whale
email: [email protected]
2 changes: 2 additions & 0 deletions apps/dash/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ metadata:
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}"
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host"
{{- end }}
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
spec:
rules:
- host: {{ .Release.Name }}.{{ .Values.global.domain }}
Expand Down
2 changes: 1 addition & 1 deletion apps/filemanager/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "0.1"
description: A Helm chart for the serve File Manager
name: filemanager
version: 1.0.2
version: 1.0.3
maintainers:
- name: Team Whale
email: [email protected]
2 changes: 2 additions & 0 deletions apps/filemanager/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ metadata:
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}"
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host"
{{- end }}
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
name: {{ .Release.Name }}-filemanager-ingress
namespace: {{ .Release.Namespace }}
spec:
Expand Down
2 changes: 1 addition & 1 deletion apps/jupyter-lab/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "0.1"
description: A Helm chart for Jupyter Lab
name: lab
version: 1.0.2
version: 1.0.3
maintainers:
- name: Team Whale
email: [email protected]
2 changes: 2 additions & 0 deletions apps/jupyter-lab/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ metadata:
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}"
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host"
#nginx.ingress.kubernetes.io/auth-response-headers: X-Forwarded-Host
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
spec:
rules:
- host: {{ .Release.Name }}.{{ .Values.global.domain }}
Expand Down
2 changes: 1 addition & 1 deletion apps/rstudio/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "0.1"
description: A Helm chart for RStudio in the browser
name: rstudio
version: 1.0.2
version: 1.0.3
maintainers:
- name: Team Whale
email: [email protected]
2 changes: 2 additions & 0 deletions apps/rstudio/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ metadata:
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}"
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host"
#nginx.ingress.kubernetes.io/auth-response-headers: X-Forwarded-Host
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
spec:
rules:
- host: {{ .Release.Name }}.{{ .Values.global.domain }}
Expand Down
2 changes: 1 addition & 1 deletion apps/shiny/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "0.1"
description: A Helm chart Shiny apps
name: shinyapp
version: 1.0.3
version: 1.0.4
maintainers:
- name: Team Whale
email: [email protected]
2 changes: 2 additions & 0 deletions apps/shiny/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ metadata:
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}"
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host"
{{- end }}
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
spec:
rules:
- host: {{ .Release.Name }}.{{ .Values.global.domain }}
Expand Down
2 changes: 1 addition & 1 deletion apps/shinyproxy/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: shinyproxy
description: A Helm chart to install Shinyproxy
type: application
version: 1.4.2
version: 1.4.3
appVersion: "0.1"
maintainers:
- name: Team Whale
Expand Down
2 changes: 2 additions & 0 deletions apps/shinyproxy/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ metadata:
{{- end }}
nginx.ingress.kubernetes.io/proxy-body-size: 2000m
#nginx.ingress.kubernetes.io/auth-response-headers: X-Forwarded-Host
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
spec:
rules:
- host: {{ .Release.Name }}.{{ .Values.global.domain }}
Expand Down
2 changes: 1 addition & 1 deletion apps/tissuumaps/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "0.1"
description: A Helm chart tissuumaps apps
name: tissuumaps
version: 1.0.2
version: 1.0.3
maintainers:
- name: Team Whale
email: [email protected]
2 changes: 2 additions & 0 deletions apps/tissuumaps/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ metadata:
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}"
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host"
{{- end }}
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
spec:
rules:
- host: {{ .Release.Name }}.{{ .Values.global.domain }}
Expand Down
2 changes: 1 addition & 1 deletion apps/vscode/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: v1
appVersion: "0.1"
description: A Helm chart for VS code in the browser
name: vscode
version: 1.0.1
version: 1.0.2
maintainers:
- name: Team Whale
email: [email protected]
2 changes: 2 additions & 0 deletions apps/vscode/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ metadata:
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}"
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host"
#nginx.ingress.kubernetes.io/auth-response-headers: X-Forwarded-Host
nginx.ingress.kubernetes.io/custom-http-errors: "503"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
spec:
rules:
- host: {{ .Release.Name }}.{{ .Values.global.domain }}
Expand Down
2,905 changes: 2,905 additions & 0 deletions k8s-error-pages/error-page-404.html

Large diffs are not rendered by default.

2,907 changes: 2,907 additions & 0 deletions k8s-error-pages/error-page-500.html

Large diffs are not rendered by default.

2,907 changes: 2,907 additions & 0 deletions k8s-error-pages/error-page-502.html

Large diffs are not rendered by default.

2,907 changes: 2,907 additions & 0 deletions k8s-error-pages/error-page-503.html

Large diffs are not rendered by default.

115 changes: 115 additions & 0 deletions serve/templates/custom-default-backend.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
# Configuration for the default backend: service and handling of a 404 error on a subdomain level (wild card domain).
---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-ingress-from-default-backend
namespace: {{ .Values.namespace | default "default" }}
spec:
podSelector:
matchLabels:
app.kubernetes.io/name: nginx-errors
policyTypes:
- Egress
egress:
- to:
- ipBlock:
cidr: 0.0.0.0/0
ports:
- protocol: TCP
port: 443
---
apiVersion: v1
kind: Service
metadata:
name: nginx-errors
labels:
app.kubernetes.io/name: nginx-errors
app.kubernetes.io/part-of: ingress-nginx
spec:
selector:
app.kubernetes.io/name: nginx-errors
app.kubernetes.io/part-of: ingress-nginx
ports:
- port: 80
targetPort: 8080
name: http
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-errors
labels:
app.kubernetes.io/name: nginx-errors
app.kubernetes.io/part-of: ingress-nginx
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: nginx-errors
app.kubernetes.io/part-of: ingress-nginx
template:
metadata:
labels:
app.kubernetes.io/name: nginx-errors
app.kubernetes.io/part-of: ingress-nginx
spec:
initContainers:
- name: fetch-error-pages
image: curlimages/curl:latest
command:
- /bin/sh
- -c
- |
mkdir -p /www
curl -o /www/404.html https://raw.githubusercontent.com/ScilifelabDataCentre/serve-charts/refs/heads/develop/k8s-error-pages/error-page-404.html
curl -o /www/503.html https://raw.githubusercontent.com/ScilifelabDataCentre/serve-charts/refs/heads/develop/k8s-error-pages/error-page-503.html
curl -o /www/502.html https://raw.githubusercontent.com/ScilifelabDataCentre/serve-charts/refs/heads/develop/k8s-error-pages/error-page-502.html
curl -o /www/500.html https://raw.githubusercontent.com/ScilifelabDataCentre/serve-charts/refs/heads/develop/k8s-error-pages/error-page-500.html
volumeMounts:
- name: error-pages
mountPath: /www
containers:
- name: nginx-error-server
image: registry.k8s.io/ingress-nginx/custom-error-pages:v1.0.2@sha256:b2259cf6bfda813548a64bded551b1854cb600c4f095738b49b4c5cdf8ab9d21
ports:
- containerPort: 8080
volumeMounts:
- name: error-pages
mountPath: /www

volumes:
- name: error-pages
emptyDir: {}
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
annotations:
nginx.ingress.kubernetes.io/custom-http-errors: 503,502,500,404
nginx.ingress.kubernetes.io/default-backend: nginx-errors
name: wildcard-serve-errors-ingress
namespace: {{ .Values.namespace }}
spec:
defaultBackend:
service:
name: nginx-errors
port:
number: 80
rules:
- host: '*.{{ .Values.domain }}'
http:
paths:
- backend:
service:
name: nginx-errors
port:
number: 80
path: /404.html
pathType: ImplementationSpecific
tls:
- hosts:
- '*.{{ .Values.domain }}'
secretName: prod-ingress

2 changes: 2 additions & 0 deletions serve/templates/ingress-platform.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ metadata:
{{- with .Values.ingress.annotations }}
{{- toYaml . | nindent 4 }}
{{- end }}
nginx.ingress.kubernetes.io/custom-http-errors: "503,502"
nginx.ingress.kubernetes.io/default-backend: nginx-errors
labels:
io.kompose.service: {{ .Release.Name }}-ingress
spec:
Expand Down
5 changes: 4 additions & 1 deletion serve/templates/studio-settings-configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ data:
# Internationalization
# https://docs.djangoproject.com/en/2.2/topics/i18n/
LANGUAGE_CODE = 'en-us'
TIME_ZONE = 'UTC'
TIME_ZONE = 'Europe/Stockholm'
USE_I18N = True
# Media Files for Studio apps
Expand Down Expand Up @@ -543,3 +543,6 @@ data:
logger_factory=structlog.stdlib.LoggerFactory(),
cache_logger_on_first_use=True,
)
# k8s cluster version for validation of manifests
CLUSTER_VERSION = "1.28"

0 comments on commit 61f259b

Please sign in to comment.