Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[do not merge] support metadata host in terraform backends #102

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/core/mlz_tf_cfg.var.sample
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.
tf_environment="{TF_ENVIRONMENT}" # https://www.terraform.io/docs/language/settings/backends/azurerm.html#environment
mlz_metadatahost="{MLZ_METADATAHOST}"
mlz_env_name="{MLZ_ENV_NAME}" # Unique name for MLZ environment
mlz_config_subid="{MLZ_CONFIG_SUBID}" # Subscription ID for Key Vault storing Service Principal creds
mlz_config_location="{MLZ_CONFIG_LOCATION}" # Azure Region for deploying Mission LZ configuration resources
Expand Down
1 change: 1 addition & 0 deletions src/scripts/apply_terraform.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ terraform init \
-backend-config "storage_account_name=${tf_be_sa_name}" \
-backend-config "container_name=${container_name}" \
-backend-config "environment=${environment}" \
-backend-config "metadata_host=${metadata_host}" \
-backend-config "tenant_id=${tenant_id}" \
-backend-config "subscription_id=${sub_id}" \
-backend-config "client_id=${client_id}" \
Expand Down
1 change: 1 addition & 0 deletions src/scripts/config/generate_vars.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,6 @@ touch "$config_vars"
echo "sp_client_id_secret_name=${mlz_sp_kv_name}"
echo "sp_client_pwd_secret_name=${mlz_sp_kv_password}"
echo "environment=${tf_environment}"
echo "metadata_host=${mlz_metadatahost}"
echo "container_name=${container_name}"
} >> "$config_vars"
1 change: 1 addition & 0 deletions src/scripts/destroy_terraform.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ terraform init \
-backend-config "storage_account_name=${tf_be_sa_name}" \
-backend-config "container_name=${container_name}" \
-backend-config "environment=${environment}" \
-backend-config "metadata_host=${metadata_host}" \
-backend-config "tenant_id=${tenant_id}" \
-backend-config "subscription_id=${sub_id}" \
-backend-config "client_id=${client_id}" \
Expand Down
1 change: 1 addition & 0 deletions src/scripts/init_terraform.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ terraform init \
-backend-config "storage_account_name=${tf_be_sa_name}" \
-backend-config "container_name=${container_name}" \
-backend-config "environment=${environment}" \
-backend-config "metadata_host=${metadata_host}" \
-backend-config "tenant_id=${tenant_id}" \
-backend-config "subscription_id=${sub_id}" \
-backend-config "client_id=${client_id}" \
Expand Down