Last active
August 10, 2023 09:20
-
-
Save pydevops/c67870b567bb9b4e07b440e0a01c913b to your computer and use it in GitHub Desktop.
Revisions
-
pydevops revised this gist
May 16, 2023 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,3 +1,6 @@ # GKE ingress in a nutshell * https://medium.com/google-cloud/ingress-in-google-kubernetes-products-f22ded21f4ed # Solution #1 (ManagedCertificate CRD in GKE) * [GKE with Google-managed SSL certificates](https://cloud.google.com/kubernetes-engine/docs/how-to/managed-certs) * Use ManagedCertificate CRD to create a object. -
pydevops revised this gist
Nov 14, 2021 . 1 changed file with 8 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -41,6 +41,14 @@ spec: `ingress.gcp.kubernetes.io/pre-shared-cert` is used by `ingress-gce` # Solution # 3 (k8s secrets) * https://cloud.google.com/kubernetes-engine/docs/how-to/ingress-multi-ssl#specifying_certificates_for_your_ingress ```bash kubectl create secret tls ci-example \ --cert ci-example.pem --key ci-example-key.pem ``` # SNI with multiple certficates * https://cloud.google.com/kubernetes-engine/docs/how-to/ingress-multi-ssl#google-managed-certs_1 -
pydevops revised this gist
Nov 14, 2021 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -40,3 +40,7 @@ spec: ``` `ingress.gcp.kubernetes.io/pre-shared-cert` is used by `ingress-gce` # SNI with multiple certficates * https://cloud.google.com/kubernetes-engine/docs/how-to/ingress-multi-ssl#google-managed-certs_1 -
pydevops revised this gist
Nov 14, 2021 . 1 changed file with 3 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,9 +1,9 @@ # Solution #1 (ManagedCertificate CRD in GKE) * [GKE with Google-managed SSL certificates](https://cloud.google.com/kubernetes-engine/docs/how-to/managed-certs) * 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. # Solution #2 (Google Cloud SSL Certificate) ## Assumption Assumes you are using the default L7 GLBC ingress controller. default for GKE cluster. * [ingress-gce](https://github.com/kubernetes/ingress-gce) @@ -22,7 +22,7 @@ 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. ## configure the GKE ingress with a preshared cert * https://cloud.google.com/kubernetes-engine/docs/how-to/load-balance-ingress#summary_of_external_ingress_annotations ``` -
pydevops revised this gist
Mar 19, 2021 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -5,7 +5,7 @@ # Solution #2 (Import a tls cert) ## Assumption Assumes you are using the default L7 GLBC ingress controller. default for GKE cluster. * [ingress-gce](https://github.com/kubernetes/ingress-gce) ## create a certficate -
pydevops renamed this gist
Mar 19, 2021 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
pydevops revised this gist
Mar 19, 2021 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,9 +1,9 @@ # Solution #1 (Use ManagedCertificate CRD) * [GKE with Google-managed SSL certificates](https://cloud.google.com/kubernetes-engine/docs/how-to/managed-certs) * 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. # Solution #2 (Import a tls cert) ## Assumption Assumes you are using the default L7 GCLB ingress controller. default for GKE cluster. * [ingress-gce](https://github.com/kubernetes/ingress-gce) -
pydevops revised this gist
Mar 19, 2021 . 1 changed file with 8 additions and 6 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,30 +1,32 @@ # Solution #1 * [GKE with Google-managed SSL certificates](https://cloud.google.com/kubernetes-engine/docs/how-to/managed-certs) * 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. # Solution #2 ## Assumption Assumes you are using the default L7 GCLB ingress controller. default for GKE cluster. * [ingress-gce](https://github.com/kubernetes/ingress-gce) ## create a certficate ``` gcloud compute ssl-certificates create ci-example --domains ci.example.com ``` ## list a certifcate ``` gcloud compute ssl-certificates list ``` ## checking certificate provisoning status ``` 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. ## configure the GKE ingress * https://cloud.google.com/kubernetes-engine/docs/how-to/load-balance-ingress#summary_of_external_ingress_annotations ``` apiVersion: networking.k8s.io/v1beta1 kind: Ingress metadata: name: ci -
pydevops renamed this gist
Feb 4, 2021 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
pydevops revised this gist
Apr 14, 2019 . 1 changed file with 5 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,9 +1,12 @@ # Solution #1 * [GKE with Google-managed SSL certificates](https://cloud.google.com/kubernetes-engine/docs/how-to/managed-certs) * Create a ManagedCertificate 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. # Solution #2 ## Assumption Assumes you are using the default L7 GLBC ingress controller. default for GKE cluster. * [ingress-gce](https://github.com/kubernetes/ingress-gce) ## create a certficate ``` -
pydevops revised this gist
Apr 14, 2019 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,5 +1,5 @@ ## References * [GKE with Google-managed SSL certificates](https://cloud.google.com/kubernetes-engine/docs/how-to/managed-certs) * [ingress-gce](https://github.com/kubernetes/ingress-gce) ## Assumption -
pydevops revised this gist
Apr 14, 2019 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,5 +1,5 @@ ## References * [GKE with Google-managed SSL certificates]https://cloud.google.com/kubernetes-engine/docs/how-to/managed-certs * [ingress-gce](https://github.com/kubernetes/ingress-gce) ## Assumption -
pydevops revised this gist
Oct 19, 2018 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -19,7 +19,7 @@ gcloud beta 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. ## configure the GKE ingress ``` apiVersion: extensions/v1beta1 kind: Ingress -
pydevops created this gist
Oct 19, 2018 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,37 @@ ## References * [Creating and Using SSL Certificates](https://cloud.google.com/load-balancing/docs/ssl-certificates) * [ingress-gce](https://github.com/kubernetes/ingress-gce) ## Assumption Assumes you are using the default L7 GLBC ingress controller. default for GKE cluster. ## create a certficate ``` gcloud beta compute ssl-certificates create ci-example --domains ci.example.com ``` ## list a certifcate ``` gcloud beta compute ssl-certificates list ``` ## checking certificate provisoning status ``` gcloud beta 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. ## modify the ingress ``` apiVersion: extensions/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`