diff --git a/README.md b/README.md index 8197165..8d49162 100644 --- a/README.md +++ b/README.md @@ -21,8 +21,7 @@ | Name | Source | Version | |------|--------|---------| | [images](#module\_images) | git@github.e.it.census.gov:terraform-modules/aws-ecr-copy-images.git/ | tf-upgrade | -| [kiali\_ingress](#module\_kiali\_ingress) | git@github.e.it.census.gov:SCT-Engineering/tfmod-gogatekeeper.git// | n/a | -| [preinstall](#module\_preinstall) | git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job | n/a | +| [preinstall](#module\_preinstall) | git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job | feature-kiali-baseline | | [service\_account](#module\_service\_account) | git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//service-account | n/a | ## Resources @@ -38,22 +37,14 @@ | Name | Description | Type | Default | Required | |------|-------------|------|---------|:--------:| -| [certificate\_issuer](#input\_certificate\_issuer) | The cluster issuer to use to create the grafana SSL certificate. | `string` | n/a | yes | | [cluster\_domain](#input\_cluster\_domain) | The domain name used to reference ingresses for the cluster | `string` | n/a | yes | | [cluster\_name](#input\_cluster\_name) | The name of the cluster into which the tools are deployed. | `string` | n/a | yes | -| [gogatekeeper\_chart\_version](#input\_gogatekeeper\_chart\_version) | When SSO information is supplied, use this gogatekeeper chart version to protect kiali/jaeger | `string` | `""` | no | -| [gogatekeeper\_registry](#input\_gogatekeeper\_registry) | When SSO information is supplied, use gogatekeeper in this registry to protect kiali/jaeger | `string` | `""` | no | -| [gogatekeeper\_repository](#input\_gogatekeeper\_repository) | When SSO information is supplied, use gogatekeeper in this repository to protect kiali/jaeger | `string` | `""` | no | -| [gogatekeeper\_tag](#input\_gogatekeeper\_tag) | When SSO information is supplied, use gogatekeeper with this tag to protect kiali/jaeger | `string` | `""` | no | | [grafana\_internal\_url](#input\_grafana\_internal\_url) | The url within the cluster to use to access grafana. | `string` | n/a | yes | | [grafana\_namespace](#input\_grafana\_namespace) | The namespace holding the grafana instance, used to look up the grafana password. | `string` | n/a | yes | | [grafana\_public\_url](#input\_grafana\_public\_url) | The URL incoming traffic from outisde the cluster uses to access grafana. | `string` | n/a | yes | | [grafana\_secret\_name](#input\_grafana\_secret\_name) | The secret in the holding the grafana admin password. | `string` | n/a | yes | | [istio\_namespace](#input\_istio\_namespace) | The namespace where istio has been deployed. | `string` | `"istio-system"` | no | | [jaeger\_internal\_url](#input\_jaeger\_internal\_url) | The url within the cluster to use to query the jaegertracing. | `string` | n/a | yes | -| [keycloak\_namespace](#input\_keycloak\_namespace) | The namespace holding the keycloak instance. | `string` | `""` | no | -| [keycloak\_public\_url](#input\_keycloak\_public\_url) | The hostname used with the cluster domain to access keycloak | `string` | `""` | no | -| [keycloak\_realm](#input\_keycloak\_realm) | The existing keycloak realm in which the client should be created | `string` | `""` | no | | [kiali\_application\_version](#input\_kiali\_application\_version) | The version of kiali to install | `string` | `"v1.73.0"` | no | | [kiali\_operator\_version](#input\_kiali\_operator\_version) | The version of kiali to install | `string` | `"1.73.0"` | no | | [namespace](#input\_namespace) | The namespace to create and into which the tools are deployed. | `string` | `"istio-tools"` | no | @@ -61,8 +52,6 @@ | [profile](#input\_profile) | The AWS\_PROFILE to use while running the scripts. | `string` | `""` | no | | [prometheus\_internal\_url](#input\_prometheus\_internal\_url) | The url within the cluster to use to query the prometheus server. | `string` | n/a | yes | | [public\_hostname](#input\_public\_hostname) | The hostname to use for kiali that will be publicly available | `string` | `"kiali"` | no | -| [sso\_client\_id](#input\_sso\_client\_id) | The client id to use for SSO | `string` | `""` | no | -| [sso\_client\_secret](#input\_sso\_client\_secret) | The secret associated with the sso\_client\_id | `string` | `""` | no | ## Outputs diff --git a/chart/kiali/.helmignore b/charts/kiali/.helmignore similarity index 100% rename from chart/kiali/.helmignore rename to charts/kiali/.helmignore diff --git a/chart/kiali/Chart.yaml b/charts/kiali/Chart.yaml similarity index 100% rename from chart/kiali/Chart.yaml rename to charts/kiali/Chart.yaml diff --git a/chart/kiali/templates/_helpers.tpl b/charts/kiali/templates/_helpers.tpl similarity index 100% rename from chart/kiali/templates/_helpers.tpl rename to charts/kiali/templates/_helpers.tpl diff --git a/chart/kiali/templates/kiali.yaml b/charts/kiali/templates/kiali.yaml similarity index 91% rename from chart/kiali/templates/kiali.yaml rename to charts/kiali/templates/kiali.yaml index 4b2d47c..541fb62 100644 --- a/chart/kiali/templates/kiali.yaml +++ b/charts/kiali/templates/kiali.yaml @@ -10,6 +10,8 @@ spec: istio_namespace: {{ .Values.istioNamespace | quote }} deployment: accessible_namespaces: "**" + image_name: {{ .Values.image_name | quote }} + # image_version: {{ .Values.image_version | quote }} external_services: grafana: auth: diff --git a/chart/kiali/templates/secret.yaml b/charts/kiali/templates/secret.yaml similarity index 92% rename from chart/kiali/templates/secret.yaml rename to charts/kiali/templates/secret.yaml index 5b5eb27..d7a530e 100644 --- a/chart/kiali/templates/secret.yaml +++ b/charts/kiali/templates/secret.yaml @@ -3,7 +3,7 @@ apiVersion: v1 kind: Secret metadata: - name: kiali + name: kiali-o labels: {{- include "kiali.labels" . | nindent 4 }} stringData: diff --git a/chart/kiali/values.yaml b/charts/kiali/values.yaml similarity index 72% rename from chart/kiali/values.yaml rename to charts/kiali/values.yaml index c8fa8b0..888c110 100644 --- a/chart/kiali/values.yaml +++ b/charts/kiali/values.yaml @@ -3,11 +3,12 @@ publicHostname: "kiali" publicDomain: "cluster.domain" istioNamespace: "istio-system" -prometheusInClusterUrl: "http://loki-prometheus-server.logging.svc.cluster.local/" +prometheusInClusterUrl: "http://loki-prometheus-server.prometheus.svc.cluster.local/" jaegerInClusterUrl: "http://istio-jaeger-query.istio-tools.svc.cluster.local:16686/" -grafanaInClusterUrl: "http://loki-grafana.logging.svc.cluster.local/" +grafanaInClusterUrl: "http://loki-grafana.grafana.svc.cluster.local/" grafanaPublicUrl: "https://grafana.cluster.domain/" -grafanaUserName: "admin" +# grafanaUserName: "admin" +grafanaUserName: "YWRtaW4=" grafanaSecretName: "kiali" grafanaSecretPasswordKey: "grafana_password" diff --git a/main.tf b/main.tf index b0fdd5e..f78cbc1 100644 --- a/main.tf +++ b/main.tf @@ -1,34 +1,31 @@ locals { - have_keycloak = ( - try(length(var.keycloak_namespace), 0) > 0 && - try(length(var.sso_client_id), 0) > 0 && - try(length(var.sso_client_secret), 0) > 0 && - try(length(var.keycloak_public_url), 0) > 0 && - try(length(var.keycloak_realm), 0) > 0 - ) ? true : false internal_hostname = format("kiali.%v.svc.cluster.local", var.namespace) internal_port_number = "20001" internal_url = format("http://%v:%v/", local.internal_hostname, local.internal_port_number) - # keycloak_issuer_uri = ( - # local.have_keycloak ? - # format("%v/realms/%v", - # var.keycloak_public_url, - # var.keycloak_realm - # ) - # : "") - kiali_oidc_secret = local.have_keycloak ? "ensure_secret kiali oidc-secret \"${var.sso_client_secret}\"" : ";" - preinstall_script = <