gifted-fall-44000
10/19/2022, 5:32 PMbored-table-20691
10/19/2022, 5:52 PMTransformations: []yaml.Transformation{
// Use an NLB instead of an ELB
func(state map[string]interface{}, opts ...pulumi.ResourceOption) {
metadata := state["metadata"].(map[string]interface{})
name := metadata["name"]
if state["kind"] == "Service" && name == "envoy" {
annotations := metadata["annotations"].(map[string]interface{})
delete(annotations, "<http://service.beta.kubernetes.io/aws-load-balancer-backend-protocol|service.beta.kubernetes.io/aws-load-balancer-backend-protocol>")
annotations["<http://service.beta.kubernetes.io/aws-load-balancer-type|service.beta.kubernetes.io/aws-load-balancer-type>"] = "nlb"
}
// We need to handle the fact we're using a wildcard cert,
// and for certain browsers (Safari), this is an issue with
// HTTP/2. As such, we only enable HTTP/1.
// Read more here: <https://projectcontour.io/resources/faq/#q-when-i-load-my-site-in-safari-it-shows-me-an-empty-page-developer-tools-show-that-the-http-response-was-421-why-does-this-happen>
if state["kind"] == "ConfigMap" && name == "contour" {
data := state["data"].(map[string]interface{})
contourConfig := data["contour.yaml"].(string)
defaultHttpVersion := "default-http-versions:\n" + "- HTTP/1.1"
contourConfig = contourConfig + "\n" + defaultHttpVersion
data["contour.yaml"] = contourConfig
}
},
},
gifted-fall-44000
10/19/2022, 5:53 PMbored-table-20691
10/19/2022, 5:54 PMgifted-fall-44000
10/19/2022, 5:55 PMbored-table-20691
10/19/2022, 5:56 PM