diff --git a/templates/component/fogg.tf.tmpl b/templates/component/fogg.tf.tmpl index 60d0ca8a0..262a6ac03 100644 --- a/templates/component/fogg.tf.tmpl +++ b/templates/component/fogg.tf.tmpl @@ -80,6 +80,17 @@ variable "tags" { } } +data "terraform_remote_state" "global" { + backend = "s3" + + config { + bucket = "{{ $out.InfraBucket }}" + key = "terraform/{{ .Project }}/global.tfstate" + region = "{{ $out.AWSRegionBackend }}" + {{ if $out.AWSProfileBackend }}profile = "{{ $out.AWSProfileBackend }}"{{ end }} + } +} + {{ range $component := .OtherComponents | sortAlpha }} data "terraform_remote_state" "{{ $component }}" { backend = "s3"