jetstack / kube-lego

DEPRECATED: Automatically request certificates for Kubernetes Ingress resources from Let's Encrypt
Apache License 2.0
2.16k stars 267 forks source link

[GCE] Can we force https ? #200

Closed adrienbarreau closed 7 years ago

adrienbarreau commented 7 years ago

Is there any way to force https ? By redirecting http requests to https ?

madziefe commented 7 years ago
ingress.kubernetes.io/force-ssl-redirect: 'true' 
or
ingress.kubernetes.io/secure-backends: 'true'

https://github.com/kubernetes/ingress/blob/master/docs/annotations.md

adrienbarreau commented 7 years ago

ingress.kubernetes.io/force-ssl-redirect and ingress.kubernetes.io/secure-backends appears to be for nginx and trafficserver. Not GCE.

hut8 commented 7 years ago

Unfortunately that seems to be the case, @adrienbarreau . I agree that GCE should support this but apparently it doesn't. Also, it seems as though this doesn't really have anything to do with this project, but should be filed in the GCE Ingress repo (although I'm sure it already has)

thecodeassassin commented 7 years ago

Yeah this is also really important for us. RIght now we force on the application side of things but there should be a better solution.

adrienbarreau commented 7 years ago

How can you force on the application side @thecodeassassin ? From my application perspective protocol is always http as the load balancer send http requests to my application. Therefore I can't check if it's http or https to do a redirection.

thecodeassassin commented 7 years ago

@adrienbarreau we use the X-Forwarded-Proto header to determine if the user used http or https.

munnerz commented 7 years ago

I'm going to close this as it's not an issue relating directly to kube-lego 😄