我可以限制批处理帐户与防火墙和Azure虚拟网络设置链接的自动存储吗?

发布于 2025-02-11 17:58:27 字数 715 浏览 3 评论 0 原文

我有批处理帐户,并在存储应用程序软件包的地方链接了自动存储。我想限制使用虚拟网络设置的此批处理链接自动存储的访问。
我尝试添加VNET设置,并允许我的Self -Host Virtual Machine量表设置代理的子网,从DevOps Pipeline我尝试执行PowerShell脚本,该脚本使用以下命令

new -azbatchapplicationpackage -AccountName $ batchaccountname- batchaccountname-- ResourcesGroupName $ resourcesGroupName -applicationId $ applicationName -applicationVersion $ newversionnumber -format zip -filePath $ packagefilepath

当启用存储网络设置所有网络时,此命令工作起来,但是当我尝试选择所选网络时,带有错误的软件包 无法添加应用程序包DataExportProcessor版本89.0。自动存储帐户键无效,请同步自动存储键。

在“存储选择网络”中,我允许我的devops比例设置代理子网,但是,我没有直接将软件包直接上传到从刻度设置机器的存储中<< strong> new-azbatchapplicationpackage 命令将应用程序包上传到存储,但是我不确定哪个IP,我应该在存储帐户中的白名单,以便批处理帐户可以更新应用程序包

I have batch account with auto storage linked where the application packages are stored. I want to restrict the access on the this batch linked auto storage with virtual network settings.
I tried adding vnet setting and allowed the subnet of my selfhost virtual machine scale set agents , from devops pipeline I am tryingto execute powershell script which uploads the application package to the batch account using below command

New-AzBatchApplicationPackage -AccountName $BatchAccountName -ResourceGroupName $ResourceGroupName -ApplicationId $ApplicationName -ApplicationVersion $newVersionNumber -Format zip -FilePath $PackageFilePath

this command works when the storage network setting all networks is enabled, but when I try to select the selected network , the command files to upload the package with the error
Failed to add application package DataExportProcessor version 89.0. The auto storage account keys are invalid, please sync auto storage keys.

In the storage selected network I am allowing my devops scale set agent subnet but , I am not uploading package directly to the storage from scale set machine, the New-AzBatchApplicationPackage command uploads the application package to storage, but I am not sure which IP , I should whitelist in my storage account so that batch account can update the application package

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

三生池水覆流年 2025-02-18 17:58:27

注意,在设置存储帐户的防火墙时,您需要选择 所有网络

如果您想选择选定的网络,则必须将公共IP地址和 batchnodemanagement 的IPS列表添加到您的存储帐户防火墙中。

要获取这些IP的列表,您可以引用此 >博客 作者 amine charot

请确保添加IPS如下:

“在此处输入image

解决 <强>“无法添加应用程序包DataExportProcessor版本89.0。自动存储帐户键无效,请同步自动存储键” 请检查存储帐户中的键和批处理帐户中的键是否相同。

如果不是像下面的同步:

转到Azure Portal - &gt;您的批处理帐户 - &gt;存储帐户 - &GT; synckeys

“在此处输入图像描述”

参考:

Please note that, while setting firewall of storage account you need to select All Networks .

If you want to choose selected network, then you have to add your public IP address and the list of the IPs of the BatchNodeManagement to your Storage Account firewall.

To get the list of those IPs, you can refer this blog by Amine Charot.

Make sure to add IPs like below:

enter image description here

To resolve the "Failed to add application package DataExportProcessor version 89.0. The auto storage account keys are invalid, please sync auto storage keys" please check whether the keys in storage account and batch account are same or not.

If not sync like below:

Go to Azure Portal -> Your Batch Account -> Storage Account -> SyncKeys

enter image description here

Reference:

Package deployment failures (microsoft.com)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文