Skip to content

Instantly share code, notes, and snippets.

View bradmccoydev's full-sized avatar

Brad McCoy bradmccoydev

View GitHub Profile
@jamesrcounts
jamesrcounts / azure-create-terraform-backend.sh
Last active August 19, 2024 12:27
Snippets to illustrate getting started with Terraform in Azure DevOps
#!/usr/bin/env bash
set -euo pipefail
ID=$(uuidgen)
LOCATION=westus
RG=terraformrg
# Create unique name for storage account
STORAGE_ACCOUNT=$(echo "terraform-${ID}" | tr '[:upper:]' '[:lower:]' | sed 's/-//g' | cut -c1-24)