Skip to content

ci: add --min-tls-version TLS1_2 to storage account creation in VHD build scripts#8210

Merged
djsly merged 4 commits into
mainfrom
copilot/fix-minimum-tls-version-policy
Mar 31, 2026
Merged

ci: add --min-tls-version TLS1_2 to storage account creation in VHD build scripts#8210
djsly merged 4 commits into
mainfrom
copilot/fix-minimum-tls-version-policy

Conversation

Copilot AI commented Mar 31, 2026

Copy link
Copy Markdown
Contributor

The CloudGov_MinTLSStorAccnt_DENY policy (enforced at management group level ~March 31, 2026) denies creation of storage accounts without minimumTlsVersion set to TLS1_2+, breaking VHD prefetch and Windows VHD builds.

Changes

  • vhdbuilder/prefetch/scripts/optimize.sh — Add --min-tls-version TLS1_2 to az storage account create in create_temp_storage (called by packer.mk prefetch target)
  • vhdbuilder/packer/produce-packer-settings-functions.sh — Add --min-tls-version TLS1_2 to az storage account create in create_windows_storage_account
-az storage account create -n "${storage_account_name}" -g "${IMAGE_BUILDER_RG_NAME}" --sku "Standard_RAGRS" --allow-shared-key-access false --location "${LOCATION}"
+az storage account create -n "${storage_account_name}" -g "${IMAGE_BUILDER_RG_NAME}" --sku "Standard_RAGRS" --allow-shared-key-access false --min-tls-version TLS1_2 --location "${LOCATION}"

e2e/config/azure.go already had MinimumTLSVersion: TLS1_2 set and required no changes.

Copilot AI changed the title [WIP] Fix CloudGov_MinTLSStorAccnt_DENY policy for storage accounts Add --min-tls-version TLS1_2 to storage account creation in VHD build scripts Mar 31, 2026
Copilot AI requested a review from djsly March 31, 2026 19:00
@djsly djsly changed the title Add --min-tls-version TLS1_2 to storage account creation in VHD build scripts fix(e2e): Add --min-tls-version TLS1_2 to storage account creation in VHD build scripts Mar 31, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates VHD build helper scripts to ensure newly created temporary storage accounts comply with the CloudGov_MinTLSStorAccnt_DENY Azure Policy by explicitly setting the minimum TLS version to TLS 1.2 during creation, preventing VHD prefetch and Windows VHD build failures.

Changes:

  • Add --min-tls-version TLS1_2 to the temp storage account creation in the prefetch optimization flow.
  • Add --min-tls-version TLS1_2 to the Windows base-image import storage account creation used by Packer settings generation.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
vhdbuilder/prefetch/scripts/optimize.sh Sets --min-tls-version TLS1_2 when creating the prefetch temporary storage account.
vhdbuilder/packer/produce-packer-settings-functions.sh Sets --min-tls-version TLS1_2 when creating the Windows build storage account.

Comment thread vhdbuilder/prefetch/scripts/optimize.sh Outdated
Comment thread vhdbuilder/packer/produce-packer-settings-functions.sh Outdated
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@djsly djsly changed the title fix(e2e): Add --min-tls-version TLS1_2 to storage account creation in VHD build scripts ci(e2e): Add --min-tls-version TLS1_2 to storage account creation in VHD build scripts Mar 31, 2026
@djsly djsly changed the title ci(e2e): Add --min-tls-version TLS1_2 to storage account creation in VHD build scripts ci: Add --min-tls-version TLS1_2 to storage account creation in VHD build scripts Mar 31, 2026
@djsly djsly changed the title ci: Add --min-tls-version TLS1_2 to storage account creation in VHD build scripts ci: add --min-tls-version TLS1_2 to storage account creation in VHD build scripts Mar 31, 2026
@djsly djsly enabled auto-merge (squash) March 31, 2026 20:52
@djsly djsly merged commit c76a30e into main Mar 31, 2026
31 of 34 checks passed
@djsly djsly deleted the copilot/fix-minimum-tls-version-policy branch March 31, 2026 20:52
timmy-wright pushed a commit that referenced this pull request Apr 2, 2026
…uild scripts (#8210)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: djsly <4981802+djsly@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
r2k1 pushed a commit that referenced this pull request Apr 8, 2026
…uild scripts (#8210)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: djsly <4981802+djsly@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[P0] CloudGov_MinTLSStorAccnt_DENY policy blocks VHD prefetch and E2E storage account creation

4 participants