Skip to content

Instantly share code, notes, and snippets.

@DanukaPraneeth
Created August 15, 2020 13:42
Show Gist options
  • Save DanukaPraneeth/b0c57d42f1879df07fdebc6b34898b20 to your computer and use it in GitHub Desktop.
Save DanukaPraneeth/b0c57d42f1879df07fdebc6b34898b20 to your computer and use it in GitHub Desktop.
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: ssotoken
annotations:
konghq.com/https-redirect-status-code: '302'
konghq.com/preserve-host: 'false'
konghq.com/protocols: https
konghq.com/strip-path: 'true'
spec:
rules:
- http:
paths:
- path: /api/service/token
backend:
serviceName: ssotoken-svc
servicePort: 8443
---
apiVersion: v1
kind: Service
metadata:
name: ssotoken-svc
annotations:
konghq.com/override: ssotoken-tokenendpoint
spec:
type: ExternalName
externalName: sso-server.com
ports:
- name: https
port: 8443
protocol: TCP
targetPort: 8443
---
apiVersion: configuration.konghq.com/v1
kind: KongIngress
metadata:
name: ssotoken-tokenendpoint
proxy:
protocol: https
path: /auth/realms/project/protocol/openid-connect/token
route:
methods:
- POST
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment