Skip to content

[User Guide] Quick Start Phase 3

github-actions edited this page Oct 2, 2024 · 6 revisions

Phase 3 of the accelerator is to run pipeline. Follow the steps below to do that.

3.1 Deploy the Landing Zone

Now you have created your bootstrapped environment you can deploy you Azure landing zone by triggering the continuous delivery pipeline in your version control system.

Note

If you encounter permission errors while running the pipelines, please note that it may take some time for permissions to fully propagate. Although the pipelines include retry logic to manage this, it can sometimes take up to 30 minutes for the permissions to take effect.

3.1.1 Azure DevOps

  1. Navigate to dev.azure.com and sign in to your organization.
  2. Navigate to your project.
  3. Click Pipelines in the left navigation.
  4. Click the 02 Azure Landing Zones Continuous Delivery pipeline.
  5. Click Run pipeline in the top right.
  6. Take the defaults and click Run.
  7. Your pipeline will run a plan.
  8. If you provided apply_approvers to the bootstrap, it will prompt you to approve the apply stage.
  9. Your pipeline will run an apply and deploy an Azure landing zone based on the starter module you choose.

3.1.2 GitHub

  1. Navigate to github.com.
  2. Navigate to your repository.
  3. Click Actions in the top navigation.
  4. Click the 02 Azure Landing Zones Continuous Delivery pipeline in the left navigation.
  5. Click Run workflow in the top right, then keep the default branch and click Run workflow.
  6. Your pipeline will run a plan.
  7. If you provided apply_approvers to the bootstrap, it will prompt you to approve the apply job.
  8. Your pipeline will run an apply and deploy an Azure landing zone based on the starter module you choose.

3.1.3 Local file system

Follow the steps below to deploy the landing zone locally. If you want to hook it up to you custom version control system, follow their documentation on how to that.

3.1.3.1 Bicep

  1. Ensure you have the latest versions of the AZ PowerShell Module and Bicep installed.
  2. Open a new PowerShell Core (pwsh) terminal or use the one you already have open.
  3. Navigate to the directory shown in the module_output_directory_path output from the bootstrap.
  4. Login to Azure using Connect-AzAccount -TenantId 00000000-0000-0000-0000-000000000000 -SubscriptionId 00000000-0000-0000-0000-000000000000.
  5. (Optional) Examine the ./scripts/deploy-local.ps1 to understand what it is doing.
  6. Run ./scripts/deploy-local.ps1.
  7. A what if will run and then you'll be prompted to check it and run the deploy.
  8. Type yes and hit enter to run the deploy.
  9. The ALZ will now be deployed, this may take some time.

3.1.3.2 Terraform

  1. Open a new PowerShell Core (pwsh) terminal or use the one you already have open.
  2. Navigate to the directory shown in the module_output_directory_path output from the bootstrap.
  3. If you choose to deploy the bootstrap resources in Azure, then you will need to navigate to the Azure Portal and find you storage account.
  4. Make note of the Resource Group Name, Storage account nameand Container Name from the storage account.
  5. If you did not choose to deploy the bootstrap resources in Azure, type terraform init and hit enter.
  6. If you choose to deploy the bootstrap resources in Azure, type terraform init -backend-config="resource_group_name=<Resource Group Name>" -backend-config="storage_account_name=<Storage account name>" -backend-config="container_name=<Container Name>" -backend-config="key=terraform.tfstate" -backend-config="use_azuread_auth=true" , replacing the items in angle brackets and hit enter.
  7. Type terraform plan -out=tfplan and hit enter.
  8. Review the plan. Use terraform show tfplan to see the plan details.
  9. If you are happy with the plan, then type terraform apply tfplan and hit enter.
  10. The ALZ will now be deployed, this may take some time.

Azure logo

Azure landing zones accelerators

Clone this wiki locally