Closed Igor-ABI closed 3 months ago
@Igor-ABI what's the response when you run invoke-webrequest "https://www.powershellgallery.com/api/v2/package/Az.Accounts/2.17.0"
?
Thks Alerickson for the answer! looks network related!
OUTPUT of the invoke-webrequest
cmdlet Invoke-WebRequest at command pipeline position 1 Supply values for the following parameters: Uri: https://www.powershellgallery.com/api/v2/package/Az.Accounts/2.17.0 Invoke-WebRequest: Network is unreachable
Prerequisites
Steps to reproduce
From Self-hosted agent for DevOps with Ubuntu 20.04.6 LTS and PowerShell 7.4.1 With root account any module installation process is failing since more than a month, any idea what can be the issue? I applied TLS1.2 mitigation but doesn't do any difference in Ubuntu [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
PS /home/Root_SH> Install-Module -Name Az.Accounts -RequiredVersion 2.17.0
Untrusted repository You are installing the modules from an untrusted repository. If you trust this repository, change its InstallationPolicy value by running the Set-PSRepository cmdlet. Are you sure you want to install the modules from 'PSGallery'? [Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "N"): Y WARNING: Source Location 'https://www.powershellgallery.com/api/v2/package/Az.Accounts/2.17.0' is not valid. Install-Package: Package 'Az.Accounts' failed to download.
Expected behavior
Actual behavior
Error details
No response
Environment data
Version
7.4.1
Visuals