Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save antigenius0910/0f9ce8a1ea38f8ead66b4b0b1ab30146 to your computer and use it in GitHub Desktop.
Save antigenius0910/0f9ce8a1ea38f8ead66b4b0b1ab30146 to your computer and use it in GitHub Desktop.
Kiali as an example
resource "kubernetes_manifest" "virtualservice_istio_system_kiali_vs" {
depends_on = [
kubernetes_manifest.k8s-istio-gateway
]
provider = kubernetes
manifest = {
"apiVersion" = "networking.istio.io/v1alpha3"
"kind" = "VirtualService"
"metadata" = {
"name" = "kiali-vs"
"namespace" = "istio-system"
}
"spec" = {
"gateways" = [
"istio-system/istio-gateway",
]
"hosts" = [
"kiali.k8s.test.com",
]
"http" = [
{
"route" = [
{
"destination" = {
"host" = "kiali"
"port" = {
"number" = 20001
}
}
},
]
},
]
}
}
}
resource "kubernetes_manifest" "destinationrule_istio_system_kiali" {
manifest = {
"apiVersion" = "networking.istio.io/v1alpha3"
"kind" = "DestinationRule"
"metadata" = {
"name" = "kiali"
"namespace" = "istio-system"
}
"spec" = {
"host" = "kiali"
"trafficPolicy" = {
"tls" = {
"mode" = "DISABLE"
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment