简体   繁体   English

如何从Microsoft Azure的Service Fabric中获取资源组名称

[英]How can I get the resource group name from within Service Fabric on Microsoft Azure

My service can be placed on different resource groups, but needs to know the name of the resource group in order to request information about the VM Scale Sets it's running on. 我的服务可以放置在不同的资源组上,但是需要知道资源组的名称才能请求有关正在运行的VM Scale Set的信息。 How do I get the name of the Resource Group which the Fabric is in from within the Fabric? 如何从结构内部获取结构所在的资源组的名称?

This may work: 这可能起作用:

If you uniquely tag your resource group, and configure the sf application to know that tag, you might be able to query the resource groups and filter by tag. 如果您对资源组进行唯一标记,并且将sf应用程序配置为知道该标记,则可以查询资源组并按标记进行过滤。 You could use a Service Principal to access the Resource manager. 您可以使用服务主体来访问资源管理器。

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

相关问题 如何获取当前Service Fabric应用程序的名称? - How can I get the name of the name of the current Service Fabric application? 如何从 Azure api 获取 Azure 资源组的成本? - How can I get the cost of an Azure Resource group from the Azure api? 如何从Azure Cloud Service的代码中获取服务名称? - How can I get the service name from code for a Azure Cloud Service? 如何获取,更新和删除Windows Azure Pack的自定义资源提供程序的计划服务配额 - how can I get, update and delete Quota of Plan Service of Custom resource provider for Windows Azure Pack 如何获取我的代码在azure fabric服务中执行的节点的名称? - how to get name of node on which my code is executing in azure fabric service? 如何使用 Microsoft.Azure.Management.Fluent 列出资源组中的资源? - How to list resources in a resource group with Microsoft.Azure.Management.Fluent? 天蓝色结构服务之外的客户端如何使用WCF服务 - How can the WCF service be consumed by a client that is outside the azure fabric service 如何从资源对象获取资源名称? - How do I get the resource name from the resource object? 如何使Service Fabric反向代理在Azure上运行 - How to get Service Fabric Reverse Proxy to work on Azure 如何在 Azure Service Fabric 应用程序中注入 IHttpClientFactory? - How do I inject IHttpClientFactory in my Azure Service Fabric application?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM