简体   繁体   English

使用Power Shell从Azure存储中导入发布设置文件

[英]Importing publish settings file from azure storage using power shell

I want to import publish settings file in powershell which is kept in azure storage. 我想在Powershell中导入发布设置文件,该文件保存在Azure存储中。 But it is not working I am trying the below command. 但是它不起作用,我正在尝试下面的命令。 If I use my local file system it works... 如果我使用本地文件系统,则可以使用...

Import-AzurePublishSettingsFile -PublishSettingsFile "https://.blob.core.windows.net/scripts/MyFile.publishsettings" Import-AzurePublishSettingsFile -PublishSettingsFile“ https://.blob.core.windows.net/scripts/MyFile.publishsettings”

How do I resolve this ? 我该如何解决?

Simply put, you can't do that because the cmdlet expects the publish settings file location to be on a local computer (and that's why when you use local file system, it works). 简而言之,您无法执行此操作,因为该cmdlet希望发布设置文件的位置位于本地计算机上(这就是为什么使用本地文件系统时它可以工作的原因)。

If you want to use a publish settings file stored in blob storage, you must download it first on the local computer (you can use Get-AzureStorageBlobContent cmdlet for that) and then provide the path where you downloaded the file to this cmdlet. 如果要使用存储在blob存储中的发布设置文件,则必须首先在本地计算机上下载它(可以使用Get-AzureStorageBlobContent cmdlet),然后提供将文件下载到此cmdlet的路径。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 使用“发布设置”文件创建 Azure 个对象 - Create Azure Objects Using 'Publish Settings' File 如何将文件从 azure 存储帐户下载到 power shell 中的临时文件变量 - how to download a file from azure storage account to a temporary file variable in power shell Powershell导入Azure发布设置无效的XML - Powershell importing Azure publish settings Invalid XML 使用带有 Power Shell 脚本的文件系统进行 Visual Studio 发布/部署 - Visual Studio Publish/Deployment using File System with Power Shell Script 添加应用程序设置到现有 Azure Web 应用程序使用 Azure 电源 Shell - Adding an App Settings to existing Azure Web Application using Azure Power Shell 有没有办法使用 Azure Power Shell 使用 YAML 文件重新部署 ACI? - Is there a way to use Azure Power Shell to redeploy an ACI using a YAML file? 使用Shell脚本列出天蓝色文件存储中已使用10天的文件 - Listing files from azure file storage that are 10 days old using shell script 如何使用Power Shell从SharePoint文件详细信息中检索? - How to retrieve from SharePoint file details using Power Shell? 使用 Power Shell 从清单文件中检索 android 版本名称 - retrieve android version name from manifest file using power shell 使用Azure Power Shell或Azure CLI创建日志分析警报 - To create the Log Analytics alerts using Azure Power Shell or Azure CLI
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM