Terraform configuration for heapster to deploy on kubernetes cluster is failing with error:
Blocks of type "selector" are not expected here. Did you mean to define
argument "selector"? If so, use the equals sign to assign it a value.
Resource configuration is:
resource "kubernetes_service" "service"{
metadata {
name="monitoring-influxdb"
namespace="kube-system"
}
spec {
selector {
k8s-app="influxdb"
}
port{
port=8086
target_port=8086
}
}
}