Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add custom headers support for ingress configuration #393

Merged
merged 1 commit into from
Mar 25, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions helm/templates/configmap.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{{- if .Values.ingress.headers -}}
apiVersion: v1
kind: ConfigMap
metadata:
name: ingress-nginx-custom-headers
labels:
{{- include "helm-chart.labels" . | nindent 4 }}
data: {{ .Values.ingress.headers | nindent 2 }}
{{- end }}
5 changes: 3 additions & 2 deletions helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,9 @@ ingress:
className: cilium
annotations:
kubernetes.io/tls-acme: "true"
nginx.ingress.kubernetes.io/configuration-snippet: |
more_set_headers "Content-Security-Policy: default-src 'self'; child-src 'self'; connect-src 'self' https://api-iam.intercom.io https://api.bako.global https://api.bako.global/socket.io https://api-js.mixpanel.com https://api.web3modal.org https://app.sentio.xyz https://hermes.pyth.network https://indexer.hyperindex.xyz https://mainnet.fuel.network https://nexus-websocket-a.intercom.io https://region1.google-analytics.com https://relay.walletconnect.org https://spark-candles.v12.trade https://testnet.fuel.network https://unleash.v12.trade https://www.google-analytics.com wss://api.bako.global/socket.io wss://indexer.hyperindex.xyz wss://nexus-websocket-a.intercom.io wss://relay.walletconnect.com wss://relay.walletconnect.org; font-src 'self' https://fonts.gstatic.com data:; frame-src 'self' https://e.widgetbot.io https://intercom.io https://s.tradingview.com https://verify.walletconnect.com https://widget.intercom.io https://widgetbot.io blob:; img-src 'self' data:; manifest-src 'self'; media-src 'self'; script-src 'self' 'unsafe-inline' 'unsafe-eval' https://cdn.jsdelivr.net https://js.intercomcdn.com https://s3.tradingview.com https://widget.intercom.io https://www.googletagmanager.com; style-src 'self' 'unsafe-inline' https://fonts.googleapis.com; upgrade-insecure-requests; worker-src 'self'; block-all-mixed-content;";
nginx.ingress.kubernetes.io/custom-headers: spark-frontend/ingress-nginx-custom-headers
headers: |
Content-Security-Policy: default-src 'self'; child-src 'self'; connect-src 'self' https://api-iam.intercom.io https://api.bako.global https://api.bako.global/socket.io https://api-js.mixpanel.com https://api.web3modal.org https://app.sentio.xyz https://hermes.pyth.network https://indexer.hyperindex.xyz https://mainnet.fuel.network https://nexus-websocket-a.intercom.io https://region1.google-analytics.com https://relay.walletconnect.org https://spark-candles.v12.trade https://testnet.fuel.network https://unleash.v12.trade https://www.google-analytics.com wss://api.bako.global/socket.io wss://indexer.hyperindex.xyz wss://nexus-websocket-a.intercom.io wss://relay.walletconnect.com wss://relay.walletconnect.org; font-src 'self' https://fonts.gstatic.com data:; frame-src 'self' https://e.widgetbot.io https://intercom.io https://s.tradingview.com https://verify.walletconnect.com https://widget.intercom.io https://widgetbot.io blob:; img-src 'self' data:; manifest-src 'self'; media-src 'self'; script-src 'self' 'unsafe-inline' 'unsafe-eval' https://cdn.jsdelivr.net https://js.intercomcdn.com https://s3.tradingview.com https://widget.intercom.io https://www.googletagmanager.com; style-src 'self' 'unsafe-inline' https://fonts.googleapis.com; upgrade-insecure-requests; worker-src 'self'; block-all-mixed-content;

resources:
requests:
Expand Down