2024-08-07 09:51:56 -04:00
|
|
|
// Copyright (c) Microsoft Corporation.
|
|
|
|
// Licensed under the MIT License.
|
|
|
|
|
2024-06-26 15:45:06 -04:00
|
|
|
param privateLinkScopeName string
|
|
|
|
param privateLinkScopedResources array = []
|
|
|
|
param queryAccessMode string = 'Open'
|
|
|
|
param ingestionAccessMode string = 'PrivateOnly'
|
|
|
|
|
2024-08-07 09:51:56 -04:00
|
|
|
|
2024-06-26 15:45:06 -04:00
|
|
|
resource privateLinkScope 'microsoft.insights/privateLinkScopes@2021-07-01-preview' = {
|
|
|
|
name: privateLinkScopeName
|
|
|
|
location: 'global'
|
|
|
|
properties: {
|
|
|
|
accessModeSettings: {
|
|
|
|
queryAccessMode: queryAccessMode
|
|
|
|
ingestionAccessMode: ingestionAccessMode
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
resource scopedResources 'microsoft.insights/privateLinkScopes/scopedResources@2021-07-01-preview' = [
|
|
|
|
for id in privateLinkScopedResources: {
|
|
|
|
name: uniqueString(id)
|
|
|
|
parent: privateLinkScope
|
|
|
|
properties: {
|
|
|
|
linkedResourceId: id
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
|
2024-08-07 09:51:56 -04:00
|
|
|
output name string = privateLinkScope.name
|
|
|
|
output id string = privateLinkScope.id
|