-
Notifications
You must be signed in to change notification settings - Fork 44
/
Copy pathingress-nginx.yml
35 lines (35 loc) · 1.85 KB
/
ingress-nginx.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#-----------------------------------------------------------------------------------------------------------------
# Example configuration for exposing spinnaker with an ingress object implemented by nginx.
#-----------------------------------------------------------------------------------------------------------------
apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
name: spin-ingress
labels:
app: spin
cluster: spin-ingress
annotations:
kubernetes.io/ingress.class: "nginx" # If the cluster has multiple ingress controllers installed, indicate which implementation to use
# All nginx ingress annotations: https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/annotations/
nginx.ingress.kubernetes.io/ssl-redirect: "true"
nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
spec:
tls: # (Optional section). Only needed if SSL termination will be done by nginx controller. SSL termination can also be done at load balancer level (i.e. for AWS using ACM certificates: https://kubernetes.github.io/ingress-nginx/deploy/#tls-termination-in-aws-load-balancer-elb)
- hosts:
- spinnaker.mycompany.com # Public facing spinnaker domain
secretName: tls-secret # There must be a secret with this name in the namespace where spinnaker is installed, of type "kubernetes.io/tls". Otherwise a self-signed certificate is used.
rules:
- host: spinnaker.mycompany.com # Public facing spinnaker domain
http:
paths:
- backend:
serviceName: spin-deck
servicePort: 9000
path: /
- host: spinnaker.mycompany.com # Public facing spinnaker domain
http:
paths:
- backend:
serviceName: spin-gate
servicePort: 8084
path: /api