逻辑应用程序+功能来填充空Azure资源标签 [英] Logic Apps + Function to fill Empty Azure Resource Tags

查看:91
本文介绍了逻辑应用程序+功能来填充空Azure资源标签的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的论坛,


我有疑问。任何人使用逻辑应用和功能填充空Azure标签?


示例方案是


1。创建资源并且您不小心忘记填写资源示例VM的成本中心和所有者以及与之相关的所有资源。


2。然后您的逻辑应用和功能将使用创建者姓名/电子邮件地址填写所有标签,并将信息填入该标签。


干杯!




解决方案

您好,


您可以结合使用事件网格,逻辑应用程序和函数(如果您愿意)。此处描述了基于活动日志事件(例如创建资源)采取操作的类似方案:  https://docs.microsoft.com/en-us/azure/event-grid/monitor-virtual-machine-changes-event-grid -logic-app  你
可以将此转换为您的场景。


但是如果您正在寻找更多"标准化"的内容。解决方案,配置Azure策略也可能适合您:


https://docs.microsoft.com/en-us/azure/governance/policy/samples/apply-tag-default-value


" 此政策
附加指定的标记名称和值(如果未提供该标记)。您指定要应用的标记名称和值。
"



Dear Forum,

I have question. Anyone filled empty Azure tags with the Logic Apps and Function?

Example scenario is that you are

1. creating resources and you accidentally forgot to fill cost center and owner of the resource example VM and all resources related ot it.

2. then your Logic Apps and Function will fill the all tags without the information using creator name/email address and fill the information to that tag.

Cheers!

解决方案

Hi,

You could use a combination of Event Grid, Logic Apps and Functions (if you want to). A similar scenario to take action based on an activity log event (such as the creation of a resource) is described here: https://docs.microsoft.com/en-us/azure/event-grid/monitor-virtual-machine-changes-event-grid-logic-app you could translate this to your scenario.

However If you're looking for a more "Standardized" solution, configuring Azure Policy might work for you as well:

https://docs.microsoft.com/en-us/azure/governance/policy/samples/apply-tag-default-value

"This policy appends a specified tag name and value, if that tag is not provided. You specify the tag name and value to apply."


这篇关于逻辑应用程序+功能来填充空Azure资源标签的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆