File tree Expand file tree Collapse file tree 3 files changed +12
-1
lines changed
Expand file tree Collapse file tree 3 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ resource "azurerm_cdn_frontdoor_secret" "this" {
3333module "diagnostic-settings" {
3434 source = " ../diagnostic-settings"
3535
36- count = var. log_analytics_workspace_id != null ? 1 : 0
36+ # count = var.log_analytics_workspace_id != null ? 1 : 0
3737
3838 name = " ${ var . name } -diagnostic-setting"
3939 target_resource_id = azurerm_cdn_frontdoor_profile. this . id
Original file line number Diff line number Diff line change @@ -58,6 +58,12 @@ resource "azurerm_virtual_desktop_workspace_application_group_association" "this
5858 workspace_id = azurerm_virtual_desktop_workspace. this . id
5959}
6060
61+ resource "azurerm_role_assignment" "avd_autoscale_hostpool" {
62+ scope = azurerm_virtual_desktop_host_pool. this . id
63+ role_definition_name = " Desktop Virtualization Power On Off Contributor"
64+ principal_id = var. principal_id
65+ }
66+
6167resource "azurerm_role_assignment" "rg_users" {
6268 scope = var. resource_group_id
6369 role_definition_name = " Virtual Machine User Login"
Original file line number Diff line number Diff line change @@ -187,3 +187,8 @@ variable "tags" {
187187 type = map (string )
188188 default = {}
189189}
190+
191+ variable "principal_id" {
192+ description = " The principal id (object id) of the identity to assign the 'Desktop Virtualization Power On Off Contributor' role to the host pool."
193+ type = string
194+ }
You can’t perform that action at this time.
0 commit comments