Skip to content

Publish PowerShell package artifacts to ACR - #3681

Merged
ramsessanchez merged 5 commits into
mainfrom
ramsessanchez/publish-powershell-artifacts-acr
Jul 31, 2026
Merged

Publish PowerShell package artifacts to ACR#3681
ramsessanchez merged 5 commits into
mainfrom
ramsessanchez/publish-powershell-artifacts-acr

Conversation

@ramsessanchez

@ramsessanchez ramsessanchez commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Summary

  • publish signed PowerShell package artifacts to Azure Container Registry from CI and release pipelines
  • assign CI packages unique ci<BuildId> prerelease versions and gate ACR deployment on relevant main-branch changes
  • add reusable PSResourceGet publishing with idempotent retries and post-publish verification

Testing

  • Invoke-Pester -Path tools\Tests\AcrPipelineHelpers.Tests.ps1
  • parsed the modified Azure Pipelines YAML files with PyYAML
  • git diff --check

Add reusable PSResourceGet publishing for signed CI and release packages, with build-specific CI prerelease versions and path-based deployment gating.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: af247b04-ecf8-4873-a78c-33d6437bb0d0
@ramsessanchez
ramsessanchez requested a review from a team as a code owner July 29, 2026 23:31
Microsoft Graph DevX Tooling added 4 commits July 29, 2026 16:45
Use shared registry and service connection variables and consume artifacts without requiring a separately provisioned Azure Pipelines environment.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: af247b04-ecf8-4873-a78c-33d6437bb0d0
Keep the publishing step template parameter-free while declaring registry and service connection variables in the Azure Pipelines that consume it.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: af247b04-ecf8-4873-a78c-33d6437bb0d0
Expose the service connection and registry values as explicit step-template parameters while retaining their definitions in the parent pipelines.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: af247b04-ecf8-4873-a78c-33d6437bb0d0
Use the alphanumeric ci<BuildId> format accepted by Update-ModuleManifest and cover it with a real manifest validation test.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: af247b04-ecf8-4873-a78c-33d6437bb0d0

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

This PR adds CI/release support for publishing signed Microsoft Graph PowerShell package artifacts to Azure Container Registry (ACR), including CI-specific prerelease versioning and change-based gating for ACR deployments.

Changes:

  • Introduces tools/AcrPipelineHelpers.ps1 to set CI prerelease suffixes in module metadata and to detect whether a commit touches ACR-relevant paths.
  • Adds a reusable Azure Pipelines template to publish .nupkg artifacts to ACR via PSResourceGet with idempotent behavior and post-publish verification.
  • Updates CI and release pipelines to deploy packages to ACR (CI gated on main-branch + relevant changes; release gated on pack+sign).

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tools/Tests/AcrPipelineHelpers.Tests.ps1 Adds Pester coverage for the prerelease setter and path relevance matcher.
tools/AcrPipelineHelpers.ps1 Adds helper functions used by CI to set prerelease versions and decide whether to publish to ACR.
.azure-pipelines/sdk-release.yml Adds an ACR deployment stage to the release pipeline.
.azure-pipelines/common-templates/publish-psresources-acr.yml New reusable template to publish and verify PowerShell packages in ACR via PSResourceGet.
.azure-pipelines/ci-build.yml Adds change detection + prerelease stamping and a gated ACR deployment stage to CI.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tools/Tests/AcrPipelineHelpers.Tests.ps1
@ramsessanchez
ramsessanchez merged commit 2592d66 into main Jul 31, 2026
8 checks passed
@ramsessanchez
ramsessanchez deleted the ramsessanchez/publish-powershell-artifacts-acr branch July 31, 2026 20:43
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.

3 participants