OctopusDeploy / WorkerTools

| Public | Officially sanctioned worker images for Octopus Deploy
0 stars 25 forks source link

Connect-AzAccount breaking change between 6.1-ubuntu.22.04 and 6.2.1-ubuntu.22.04 #95

Open bugged84 opened 1 month ago

bugged84 commented 1 month ago

Using the Run an Azure Script step template with a powershell script works with octopusdeploy/worker-tools:6.1-ubuntu.22.04 container image, but not with octopusdeploy/worker-tools:6.2.1-ubuntu.22.04 container image.

image

kengibous commented 1 month ago

This occurs when using OIDC

Setting Proxy Environment Variables 
Name                           Value 
----                           ----- 
PSVersion                      7.4.1 
PSEdition                      Core 
GitCommitId                    7.4.1 
OS                             Ubuntu 22.04.4 LTS 
Platform                       Unix 
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…} 
PSRemotingProtocolVersion      2.3 
SerializationVersion           1.1.0.1 
WSManStackVersion              3.0 
PowerShell Environment Information: 
  OperatingSystem: Unix 5.15.0.10[60](<redacted>) 
  OsBitVersion: x64 
  Is64BitProcess: True 
  CurrentDirectory: /etc/octopus/Work/h0svyZvkRUS5CZu5akQSyg 
  CurrentLocation: /etc/octopus/Work/h0svyZvkRUS5CZu5akQSyg 
  TempDirectory: /tmp/ 
  HostProcess: pwsh (15) 
Initializing ConditionalAssemblyContext. PSEdition is [Core]. PSVersion is [7.4.1]. 
Initializing ConditionalAssemblyProvider. AssemblyRootPath is [/usr/local/share/powershell/Modules/Az.Accounts/2.16.0/StartupScripts/../lib]. 
Registering Az shared AssemblyLoadContext. 
AssemblyLoadContext registered. 
Enabling AzureRM aliasing 
Mode             : Process 
ContextDirectory : None 
ContextFile      : None 
CacheDirectory   : None 
CacheFile        : None 
KeyStoreFile     : None 
Settings         : {[InstallationId, [63](<redacted>)e835d5-6a01-4f9c-b424-9af5c38176f8]} 
Az Modules: Authenticating with OpenID Connect Federated Token 
Attempt 1 of 5 failed: ClientAssertionCredential authentication failed: Persistence check failed. Inspect inner exception for details 
Could not find tenant id for provided tenant domain '<redacted>'.  
Waiting for 5 seconds before retrying... 
Retrying... 
Mode             : Process 
ContextDirectory : None 
ContextFile      : None 
CacheDirectory   : None 
CacheFile        : None 
KeyStoreFile     : None 
Settings         : {[InstallationId, 63e835d5-6a01-4f9c-b424-9af5c38176f8]} 
WARNING: You're using Az version 11.3.0. The latest version of Az is 12.1.0. Upgrade your Az modules using the following commands: 
  Update-PSResource Az -WhatIf    -- Simulate updating your Az modules. 
  Update-PSResource Az            -- Update your Az modules. 
There will be breaking changes from 11.3.0 to 12.1.0. Open https://go.microsoft.com/fwlink/?(<redacted>) and check the details. 
Az Modules: Authenticating with OpenID Connect Federated Token