Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to disable http traffic and force https with kubernetes ingress on gcloud

Hi i tried the new annotation for ingress explained here

apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: ssl-iagree-ingress
  annotations:
   kubernetes.io/ingress.allowHTTP: "false"
spec:
  tls:
  - secretName: secret-cert-myown
  backend:
    serviceName: modcluster
    servicePort: 80

but i can still access it trough http, this is my setup on gcloud ingress--apache:80

like image 953
PaulMB Avatar asked Aug 17 '16 18:08

PaulMB


1 Answers

Well i was able to resolve the issue, thanks to Mr Danny, from this pull request here, there was a typo in

kubernetes.io/ingress.allowHTTP: "false"

change it to

kubernetes.io/ingress.allow-http: "false"

and it works fine now.

ps: only for master version 1.3.5

like image 194
PaulMB Avatar answered Nov 15 '22 08:11

PaulMB