- GKE with Google-managed SSL certificates
- Use ManagedCertificate CRD to create a object.
- Associate the ManagedCertificate object to an Ingress by adding an annotation networking.gke.io/managed-certificates to the Ingress. This annotation is a comma-separated list of ManagedCertificate resources, cert1,cert2,cert3 for example.
Assumes you are using the default L7 GLBC ingress controller. default for GKE cluster.
gcloud compute ssl-certificates create ci-example --domains ci.example.com
gcloud compute ssl-certificates list
gcloud compute ssl-certificates describe ci-example
Please note with a correct configuration the total time for provisioning certificates is likely to take from 30 to 60 minutes.
apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
name: ci
namespace: ci
annotations:
ingress.gcp.kubernetes.io/pre-shared-cert: 'ci-example'
spec:
backend:
serviceName: jenkins-ui
servicePort: 8080
ingress.gcp.kubernetes.io/pre-shared-cert
is used by ingress-gce
kubectl create secret tls ci-example \
--cert ci-example.pem --key ci-example-key.pem