Skip to content

Detection of Cloud Deployment Flow using registry key#29053

Merged
vidai-msft merged 2 commits intoAzure:mainfrom
Samhitha-Microsoft:user/samhitham/AddRegKey
Jan 13, 2026
Merged

Detection of Cloud Deployment Flow using registry key#29053
vidai-msft merged 2 commits intoAzure:mainfrom
Samhitha-Microsoft:user/samhitham/AddRegKey

Conversation

@Samhitha-Microsoft
Copy link
Copy Markdown
Contributor

@Samhitha-Microsoft Samhitha-Microsoft commented Jan 12, 2026

Description

Previously, when the cloud deployment is done, the nodes would be ARC enabled prior. But, when repair registration is triggered, The ARc enablement is being triggered again which should not be happening. This was happening because the env variable that was used to determine the cloud deployment flow would be expired after the first scenario.

Mandatory Checklist

  • SHOULD update ChangeLog.md file(s) appropriately
    • Update src/{{SERVICE}}/{{SERVICE}}/ChangeLog.md.
      • A snippet outlining the change(s) made in the PR should be written under the ## Upcoming Release header in the past tense.
    • Should not change ChangeLog.md if no new release is required, such as fixing test case only.
  • SHOULD regenerate markdown help files if there is cmdlet API change. Instruction
  • SHOULD have proper test coverage for changes in pull request.
  • SHOULD NOT adjust version of module manually in pull request

Copilot AI review requested due to automatic review settings January 12, 2026 11:12
@azure-client-tools-bot-prd
Copy link
Copy Markdown

Thanks for your contribution! The pull request validation has started. Please revisit this comment for updated status.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This pull request improves the detection mechanism for cloud deployment scenarios in Azure Stack HCI registration. Previously, the detection relied solely on an environment variable that expired after initial deployment, causing ARC enablement to be incorrectly triggered again during repair registration. The fix adds a persistent registry key check as a fallback detection method.

Changes:

  • Added registry-based detection for cloud deployment scenarios to supplement the existing environment variable check
  • Updated the ChangeLog to document the enhancement

Reviewed changes

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

File Description
src/StackHCI/StackHCI/ChangeLog.md Documents the new cloud deployment detection mechanism using registry key
src/StackHCI/StackHCI.Autorest/custom/stackhci.ps1 Enhances ValidateCloudDeployment function with registry key fallback check and improved logging

@isra-fel
Copy link
Copy Markdown
Member

/azp run

@azure-pipelines
Copy link
Copy Markdown
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@vidai-msft
Copy link
Copy Markdown
Contributor

@Samhitha-Microsoft Az 15.2.0 has already been finalized. The PR will be merged and released in the next version.

Copy link
Copy Markdown
Contributor

@vidai-msft vidai-msft left a comment

Choose a reason for hiding this comment

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

Please address the review comment.

@Samhitha-Microsoft
Copy link
Copy Markdown
Contributor Author

@Samhitha-Microsoft Az 15.2.0 has already been finalized. The PR will be merged and released in the next version.

Okay, we can take it in the next release.

@Samhitha-Microsoft
Copy link
Copy Markdown
Contributor Author

Please address the review comment.

Updated the message.

Copy link
Copy Markdown
Contributor

@vidai-msft vidai-msft left a comment

Choose a reason for hiding this comment

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

LGTM

@vidai-msft
Copy link
Copy Markdown
Contributor

/azp run azure-powershell - security-tools

@azure-pipelines
Copy link
Copy Markdown
Contributor

Azure Pipelines successfully started running 1 pipeline(s).

@isra-fel
Copy link
Copy Markdown
Member

/azp run

@vidai-msft vidai-msft enabled auto-merge (squash) January 13, 2026 06:08
@azure-pipelines
Copy link
Copy Markdown
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@vidai-msft
Copy link
Copy Markdown
Contributor

/azp run

@azure-pipelines
Copy link
Copy Markdown
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@vidai-msft vidai-msft merged commit 04a37e3 into Azure:main Jan 13, 2026
12 checks passed
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.

4 participants