Install-Module - Unable to resolve package source 'https://www.powershellgallery.com/api/v2/'
When you attempt to run any Install-Module or Find-Module cmdlets and get the below error,
Error:
WARNING: Unable
to resolve package source 'https://www.powershellgallery.com/api/v2/' |
Solution:
Run the PowerShell as Administrator and run the below cmdlet, which will enable the TLS 1.2 in the PowerShell which should allow you to execute the Install-Module cmdlets,
[Net.ServicePointManager]::SecurityProtocol
= [Net.SecurityProtocolType]::Tls12 |
Note: You may run the below cmdlet to check current protocol type used by your PowerShell and also after running the above mentioned cmdlet and ensure it is updated.
[Net.ServicePointManager]::SecurityProtocol |
Comments
Post a Comment