@@ -19,20 +19,59 @@ Azure environment cost ballpark [estimate](https://tinyurl.com/y4e9s7rf). This i
1. Azure Subscription
1. Terraform and Go are locally installed.
1. Requires the use of [direnv](https://direnv.net/).
1. Install the required common tools (kubectl, helm, and terraform). Currently uses [Terraform 0.12.29](https://releases.hashicorp.com/terraform/0.12.29/) and [GO 1.12.14](https://golang.org/dl/).
1. Install the required common tools (kubectl, helm, and terraform).
### Install the required tooling
This document assumes one is running a current version of Ubuntu. Windows users can install the Ubuntu Terminal from the Microsoft Store. The Ubuntu Terminal enables Linux command-line utilities, including bash, ssh, and git that will be useful for the following deployment. _Note: You will need the Windows Subsystem for Linux installed to use the Ubuntu Terminal on Windows_.
Currently the versions in use are [Terraform 0.12.29](https://releases.hashicorp.com/terraform/0.12.29/) and [GO 1.12.14](https://golang.org/dl/).
> Note: Terraform and Go are recommended to be installed using a [Terraform Version Manager](https://github.com/tfutils/tfenv) and a [Go Version Manager](https://github.com/stefanmaric/g)
### Install the Azure CLI
For information specific to your operating system, see the [Azure CLI install guide](https://docs.microsoft.com/en-us/cli/azure/install-azure-cli?view=azure-cli-latest). You can also use [this script](https://github.com/microsoft/bedrock/blob/master/tools/prereqs/setup_azure_cli.sh) if running on a Unix based machine.
For information specific to your operating system, see the [Azure CLI install guide](https://docs.microsoft.com/en-us/cli/azure/install-azure-cli?view=azure-cli-latest). You can also use the single command install if running on a Unix based machine.
Infrastructure assumes bring your own Elastic Search Instance at a version of 6.8.x and access information must be stored in the Common KeyVault.
Infrastructure requires a bring your own Elastic Search Instance of a version of 6.8.x with a valid https endpoint and the access information must now be stored in the Common KeyVault. The recommended method of Elastic Search is to use the [Elastic Cloud Managed Service from the Marketplace](https://azuremarketplace.microsoft.com/en-us/marketplace/apps/elastic.ec-azure?tab=Overview).
> Note: Elastic Cloud Managed Service requires a Credit Card to be associated to the subscription for billing purposes.
```bash
ENDPOINT=""
USERNAME=""
PASSWORD=""
az keyvault secret set--vault-name$COMMON_VAULT--name"elastic-endpoint-dp1-demo"--value$ENDPOINT
az keyvault secret set--vault-name$COMMON_VAULT--name"elastic-username-dp1-demo"--value$USERNAME
az keyvault secret set--vault-name$COMMON_VAULT--name"elastic-password-dp1-demo"--value$PASSWORD
ES_ENDPOINT=""
ES_USERNAME=""
ES_PASSWORD=""
az keyvault secret set--vault-name$COMMON_VAULT--name"elastic-endpoint-dp1-demo"--value$ES_ENDPOINT
az keyvault secret set--vault-name$COMMON_VAULT--name"elastic-username-dp1-demo"--value$ES_USERNAME
az keyvault secret set--vault-name$COMMON_VAULT--name"elastic-password-dp1-demo"--value$ES_PASSWORD
export TF_VAR_elasticsearch_endpoint="$(az keyvault secret show --vault-name$COMMON_VAULT--id https://$COMMON_VAULT.vault.azure.net/secrets/elastic-endpoint-dp1-demo --query value -otsv)"
export TF_VAR_elasticsearch_username="$(az keyvault secret show --vault-name$COMMON_VAULT--id https://$COMMON_VAULT.vault.azure.net/secrets/elastic-username-dp1-demo --query value -otsv)"
export TF_VAR_elasticsearch_password="$(az keyvault secret show --vault-name$COMMON_VAULT--id https://$COMMON_VAULT.vault.azure.net/secrets/elastic-password-dp1-demo --query value -otsv)"
export TF_VAR_elasticsearch_endpoint="$(az keyvault secret show --id https://$COMMON_VAULT.vault.azure.net/secrets/elastic-endpoint-dp1-demo --query value -otsv)"
export TF_VAR_elasticsearch_username="$(az keyvault secret show --id https://$COMMON_VAULT.vault.azure.net/secrets/elastic-username-dp1-demo --query value -otsv)"
export TF_VAR_elasticsearch_password="$(az keyvault secret show --id https://$COMMON_VAULT.vault.azure.net/secrets/elastic-password-dp1-demo --query value -otsv)"
EOF
...
...
@@ -149,7 +187,6 @@ The public key of the `azure-aks-gitops-ssh-key` previously created needs to be
@@ -29,6 +29,8 @@ Create the helm chart values file necessary to install charts.
- Edit the newly downloaded [config.yaml](https://community.opengroup.org/osdu/platform/deployment-and-operations/infra-azure-provisioning/-/raw/master/charts/helm-config.yaml) and fill out the required sections `azure`, `ingress` and `istio`.
export ARM_CLIENT_ID="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-terraform-id--query value -otsv)"
export ARM_CLIENT_SECRET="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-terraform-key--query value -otsv)"
export ARM_ACCESS_KEY="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osducommon${RANDOM_NUMBER}-storage-key--query value -otsv)"
export ARM_CLIENT_ID="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-terraform-id--query value -otsv)"
export ARM_CLIENT_SECRET="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-terraform-key--query value -otsv)"
export ARM_ACCESS_KEY="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osducommon${RANDOM_NUMBER}-storage-key--query value -otsv)"
export TF_VAR_remote_state_account="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osducommon${RANDOM_NUMBER}-storage--query value -otsv)"
export TF_VAR_remote_state_account="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osducommon${RANDOM_NUMBER}-storage--query value -otsv)"
export TF_VAR_principal_appId="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-principal-id--query value -otsv)"
export TF_VAR_principal_appId="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-principal-id--query value -otsv)"
export TF_VAR_principal_password="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-principal-key--query value -otsv)"
export TF_VAR_principal_objectId="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-principal-oid--query value -otsv)"
export TF_VAR_principal_password="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-principal-key--query value -otsv)"
export TF_VAR_principal_objectId="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-principal-oid--query value -otsv)"
export TF_VAR_application_clientid="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-application-clientid--query value -otsv)"
export TF_VAR_application_secret="$(az keyvault secret show --vault-name$AZURE_VAULT--id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-application-secret--query value -otsv)"
export TF_VAR_application_clientid="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-application-clientid--query value -otsv)"
export TF_VAR_application_secret="$(az keyvault secret show --id https://$AZURE_VAULT.vault.azure.net/secrets/osdu-mvp-${UNIQUE}-application-secret--query value -otsv)"