无法安装Azure RM Ubuntu 16.04

时间:2017-06-26 15:27:39

标签: azure azure-powershell

我正在使用带有高级PS shell的Ubuntu 16.04。已安装适当版本的PowershellGet。

https://docs.microsoft.com/en-us/powershell/azure/install-azurerm-ps?view=azurermps-4.1.0

尝试按照上述说明操作时,我会收到以下错误:

PackageManagement \ Install-Package:Package' AzureRM.profile'无法安装,因为:/tmp/1323106488/AzureRM.profile/AzureRM.profile.nuspec at /opt/microsoft/powershell/6.0.0alpha.14/Modules/PowerShellGet/1.1.2.0/PSModule.psm1:1809 char:21 + ... $ null = PackageManagement \ Install-Package @PSBoundParameters + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~ + CategoryInfo:InvalidResult:(AzureRM.profile:String)[Install-Package],异常+ FullyQualifiedErrorId:Package' {0}'无法安装,因为:{1},Microsoft.PowerShell.PackageManagement.Cmdlets.InstallPackage

我错过了一步吗?

1 个答案:

答案 0 :(得分:1)

基本上你正在将一个Windows教程应用到一个ubuntu盒子,并想知道为什么它不起作用......

Install-Package -Name AzureRM.NetCore.Preview -Source https://www.powershellgallery.com/api/v2 -ProviderName NuGet -ExcludeVersion -Destination <Folder you want this to be installed>

您可以按照this article安装AzureRM.Profile和AzureRm.Resources(我认为这些是目前移植的唯一内容)。

有一个实验性码头图像,周围有一些其他模块,我现在似乎无法找到它

docker run -it twitchax/azure-powershell-core
你在这里;这个有:

AzureRM.Compute.Netcore
AzureRM.Network.Netcore
AzureRM.Profile.Netcore
AzureRM.Resources.Netcore
AzureRM.Storage.Netcore
AzureRM.Tags.Netcore
AzureRM.Websites.Netcore