diff --git a/README.md b/README.md index 1c69fe7..2934864 100644 --- a/README.md +++ b/README.md @@ -89,9 +89,9 @@ Common issues and solutions: | [images](#module\_images) | git@github.e.it.census.gov:terraform-modules/aws-ecr-copy-images.git/ | tf-upgrade | | [ingress\_resources](#module\_ingress\_resources) | git::https://github.e.it.census.gov/SCT-Engineering/tfmod-istio-service-ingress.git | n/a | | [keycloak\_db\_config](#module\_keycloak\_db\_config) | git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job | n/a | -| [post\_install](#module\_post\_install) | git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job | n/a | -| [pre\_install](#module\_pre\_install) | git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job | n/a | -| [service\_account](#module\_service\_account) | git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//service-account | n/a | +| [post\_install](#module\_post\_install) | git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//config-job | n/a | +| [pre\_install](#module\_pre\_install) | git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//config-job | n/a | +| [service\_account](#module\_service\_account) | git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//service-account | n/a | ## Resources diff --git a/main.tf b/main.tf index 945c7f3..7550123 100644 --- a/main.tf +++ b/main.tf @@ -52,7 +52,7 @@ EOF do_kubectl_cp /tmp/db_config.sql keycloak-db-postgresql-0 /tmp/db_config.sql do_kubectl exec -n keycloak -t keycloak-db-postgresql-0 -c postgresql -- \ /opt/bitnami/postgresql/bin/psql \ - postgresql://postgres:${data.kubernetes_secret.db-secrets.data.password}@keycloak-db-postgresql.keycloak.svc.cluster.local:5432/keycloak \ + postgresql://postgres:${data.kubernetes_secret.db-secrets.data.password}@keycloak-db-postgresql.${var.keycloak_namespace}.svc.cluster.local:5432/keycloak \ -f /tmp/db_config.sql echo "End DB Config Job" CONFIG @@ -68,17 +68,17 @@ resource "kubernetes_namespace" "keycloak" { } module "service_account" { - # source = "git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//service-account" # tflint-ignore: terraform_module_pinned_source - source = "git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//service-account" + source = "git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//service-account" + # source = "git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//service-account" namespace = kubernetes_namespace.keycloak.metadata[0].name } module "pre_install" { - # source = "git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//config-job" # tflint-ignore: terraform_module_pinned_source - source = "git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job" + source = "git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//config-job" + # source = "git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job" namespace = kubernetes_namespace.keycloak.metadata[0].name service_account_name = module.service_account.service_account_name @@ -95,7 +95,7 @@ resource "helm_release" "keycloak-db" { version = var.postgresql_chart_version name = "keycloak-db" namespace = kubernetes_namespace.keycloak.metadata[0].name - repository = "oci://registry-1.docker.io/bitnamicharts" + repository = "${path.module}/charts/postgresql" values = [file("${path.module}/keycloak-db-values.yaml")] wait = true timeout = 300 @@ -149,7 +149,7 @@ resource "helm_release" "keycloak" { name = "keycloak" namespace = kubernetes_namespace.keycloak.metadata[0].name version = var.keycloak_chart_version - repository = "https://codecentric.github.io/helm-charts" + repository = "${path.module}/charts/keycloakx" timeout = 300 depends_on = [helm_release.keycloak-db] @@ -188,9 +188,9 @@ module "ingress_resources" { module "post_install" { depends_on = [helm_release.keycloak] - # source = "git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//config-job" # tflint-ignore: terraform_module_pinned_source - source = "git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job" + source = "git::https://github.e.it.census.gov/SCT-Engineering/tfmod-config-job.git//config-job" + # source = "git@github.e.it.census.gov:SCT-Engineering/tfmod-config-job.git//config-job" namespace = kubernetes_namespace.keycloak.metadata[0].name service_account_name = module.service_account.service_account_name