Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jul 24, 2025

Simplified Azure authentication in deployment workflows by removing conditionals and consolidating to a single login step using Federated Credentials.

Changes Made

azure-dev.yaml:

  • Removed if: ${{ env.AZURE_CLIENT_ID != '' }} conditional from the Azure login step
  • Login step now executes unconditionally using Federated Credentials

evaluate.yaml:

  • Removed if: ${{ env.AZURE_CLIENT_ID != '' }} conditional from the azd login step
  • Removed the azure/login@v2 action that used Client Credentials
  • Removed the dependent "Set az account" step
  • Now has a single, unconditional login step using Federated Credentials

Both workflow files now have exactly the login format specified in the issue:

- name: Log in with Azure (Federated Credentials)
  run: |
    azd auth login `
      --client-id "$Env:AZURE_CLIENT_ID" `
      --federated-credential-provider "github" `
      --tenant-id "$Env:AZURE_TENANT_ID"
  shell: pwsh

Benefits

  • Simplifies workflow logic by removing conditionals
  • Reduces complexity and potential failure points
  • Ensures consistent authentication method across workflows
  • Follows current best practices for Azure authentication in GitHub Actions

Fixes #239.


💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.

… Credentials auth

Co-authored-by: pamelafox <297042+pamelafox@users.noreply.github.com>
Copilot AI changed the title [WIP] Remove conditional from Azure login step in deployment workflow Remove conditional Azure login steps and simplify to single Federated Credentials auth Jul 24, 2025
Copilot AI requested a review from pamelafox July 24, 2025 20:21
Copilot finished work on behalf of pamelafox July 24, 2025 20:21
@pamelafox pamelafox marked this pull request as ready for review July 25, 2025 05:49
@pamelafox pamelafox merged commit 4922e20 into main Jul 25, 2025
2 checks passed
@pamelafox pamelafox deleted the copilot/fix-239 branch July 25, 2025 05:49
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.

Remove conditional from Azure login step in deployment workflow

2 participants