Hiermee haalt u alle herstelbewerkingen voor een resource op.
GET https://management.azure.com/{resourceId}/providers/Microsoft.PolicyInsights/remediations?api-version=2021-10-01
With optional parameters:
GET https://management.azure.com/{resourceId}/providers/Microsoft.PolicyInsights/remediations?$top={$top}&$filter={$filter}&api-version=2021-10-01
URI-parameters
Name |
In |
Vereist |
Type |
Description |
resourceId
|
path |
True
|
string
|
Resource-id.
|
api-version
|
query |
True
|
string
|
Client-API-versie.
|
$filter
|
query |
|
string
|
OData-filterexpressie.
|
$top
|
query |
|
integer
int32
|
Maximum aantal records dat moet worden geretourneerd.
|
Antwoorden
Name |
Type |
Description |
200 OK
|
RemediationListResult
|
De opgehaalde herstelbewerkingen.
|
Other Status Codes
|
ErrorResponse
|
Foutreactie waarin wordt beschreven waarom de bewerking is mislukt.
|
Beveiliging
azure_auth
Azure Active Directory OAuth2-stroom
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Scopes
Name |
Description |
user_impersonation
|
uw gebruikersaccount imiteren
|
Voorbeelden
Sample Request
GET https://management.azure.com/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1/providers/Microsoft.PolicyInsights/remediations?api-version=2021-10-01
import com.azure.core.util.Context;
/** Samples for Remediations ListForResource. */
public final class Main {
/*
* x-ms-original-file: specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope.json
*/
/**
* Sample code: List remediations at individual resource scope.
*
* @param manager Entry point to PolicyInsightsManager.
*/
public static void listRemediationsAtIndividualResourceScope(
com.azure.resourcemanager.policyinsights.PolicyInsightsManager manager) {
manager
.remediations()
.listForResource(
"subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1",
null,
null,
Context.NONE);
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.policyinsights import PolicyInsightsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-policyinsights
# USAGE
python remediations_list_resource_scope.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = PolicyInsightsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.remediations.list_for_resource(
resource_id="subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1",
)
for item in response:
print(item)
# x-ms-original-file: specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armpolicyinsights_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/policyinsights/armpolicyinsights"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/05a9cdab363b8ec824094ee73950c04594325172/specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope.json
func ExampleRemediationsClient_NewListForResourcePager_listRemediationsAtIndividualResourceScope() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armpolicyinsights.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewRemediationsClient().NewListForResourcePager("subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1", &armpolicyinsights.QueryOptions{Top: nil,
Filter: nil,
OrderBy: nil,
Select: nil,
From: nil,
To: nil,
Apply: nil,
SkipToken: nil,
Expand: nil,
}, nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.RemediationListResult = armpolicyinsights.RemediationListResult{
// Value: []*armpolicyinsights.Remediation{
// {
// Name: to.Ptr("790996e6-9871-4b1f-9cd9-ec42cd6ced1e"),
// Type: to.Ptr("Microsoft.PolicyInsights/remediations"),
// ID: to.Ptr("/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1/providers/microsoft.policyinsights/remediations/790996e6-9871-4b1f-9cd9-ec42cd6ced1e"),
// Properties: &armpolicyinsights.RemediationProperties{
// CorrelationID: to.Ptr("a14e1d60-dae9-4771-b4be-a556d69e77a6"),
// CreatedOn: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-09-13T21:51:09.075Z"); return t}()),
// DeploymentStatus: &armpolicyinsights.RemediationDeploymentSummary{
// FailedDeployments: to.Ptr[int32](0),
// SuccessfulDeployments: to.Ptr[int32](1),
// TotalDeployments: to.Ptr[int32](1),
// },
// FailureThreshold: &armpolicyinsights.RemediationPropertiesFailureThreshold{
// Percentage: to.Ptr[float32](0.1),
// },
// LastUpdatedOn: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-09-13T21:52:10.001Z"); return t}()),
// ParallelDeployments: to.Ptr[int32](6),
// PolicyAssignmentID: to.Ptr("/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.authorization/policyassignments/b101830944f246d8a14088c5"),
// ProvisioningState: to.Ptr("Succeeded"),
// ResourceCount: to.Ptr[int32](42),
// ResourceDiscoveryMode: to.Ptr(armpolicyinsights.ResourceDiscoveryModeExistingNonCompliant),
// StatusMessage: to.Ptr("Remediation extended status"),
// },
// SystemData: &armpolicyinsights.SystemData{
// CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-09-13T21:49:16.463Z"); return t}()),
// CreatedBy: to.Ptr("b69a9388-9488-4534-b470-7ec6d41beef6"),
// CreatedByType: to.Ptr(armpolicyinsights.CreatedByTypeUser),
// LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-09-13T21:50:18.464Z"); return t}()),
// LastModifiedBy: to.Ptr("b69a9388-9488-4534-b470-7ec6d41beef6"),
// LastModifiedByType: to.Ptr(armpolicyinsights.CreatedByTypeUser),
// },
// }},
// }
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { PolicyInsightsClient } = require("@azure/arm-policyinsights");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to Gets all remediations for a resource.
*
* @summary Gets all remediations for a resource.
* x-ms-original-file: specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope.json
*/
async function listRemediationsAtIndividualResourceScope() {
const subscriptionId =
process.env["POLICYINSIGHTS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000";
const resourceId =
"subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1";
const credential = new DefaultAzureCredential();
const client = new PolicyInsightsClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.remediations.listForResource(resourceId)) {
resArray.push(item);
}
console.log(resArray);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
using System;
using System.Threading.Tasks;
using Azure;
using Azure.Core;
using Azure.Identity;
using Azure.ResourceManager;
using Azure.ResourceManager.PolicyInsights;
// Generated from example definition: specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope.json
// this example is just showing the usage of "Remediations_ListForResource" operation, for the dependent resources, they will have to be created separately.
// get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line
TokenCredential cred = new DefaultAzureCredential();
// authenticate your client
ArmClient client = new ArmClient(cred);
// this example assumes you already have this ArmResource created on azure
// for more information of creating ArmResource, please refer to the document of ArmResource
// get the collection of this PolicyRemediationResource
string resourceId = "subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1";
ResourceIdentifier scopeId = new ResourceIdentifier(string.Format("/{0}", resourceId));
PolicyRemediationCollection collection = client.GetPolicyRemediations(scopeId);
// invoke the operation and iterate over the result
await foreach (PolicyRemediationResource item in collection.GetAllAsync())
{
// the variable item is a resource, you could call other operations on this instance as well
// but just for demo, we get its data from this resource instance
PolicyRemediationData resourceData = item.Data;
// for demo we just print out the id
Console.WriteLine($"Succeeded on id: {resourceData.Id}");
}
Console.WriteLine($"Succeeded");
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Sample Response
{
"value": [
{
"properties": {
"policyAssignmentId": "/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.authorization/policyassignments/b101830944f246d8a14088c5",
"provisioningState": "Succeeded",
"createdOn": "2018-09-13T21:51:09.075918Z",
"lastUpdatedOn": "2018-09-13T21:52:10.0011706Z",
"resourceDiscoveryMode": "ExistingNonCompliant",
"deploymentStatus": {
"totalDeployments": 1,
"successfulDeployments": 1,
"failedDeployments": 0
},
"statusMessage": "Remediation extended status",
"correlationId": "a14e1d60-dae9-4771-b4be-a556d69e77a6",
"resourceCount": 42,
"parallelDeployments": 6,
"failureThreshold": {
"percentage": 0.1
}
},
"id": "/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1/providers/microsoft.policyinsights/remediations/790996e6-9871-4b1f-9cd9-ec42cd6ced1e",
"name": "790996e6-9871-4b1f-9cd9-ec42cd6ced1e",
"type": "Microsoft.PolicyInsights/remediations",
"systemData": {
"createdBy": "b69a9388-9488-4534-b470-7ec6d41beef6",
"createdByType": "User",
"createdAt": "2018-09-13T21:49:16.4638131Z",
"lastModifiedBy": "b69a9388-9488-4534-b470-7ec6d41beef6",
"lastModifiedByType": "User",
"lastModifiedAt": "2018-09-13T21:50:18.4647478Z"
}
}
]
}
Sample Request
GET https://management.azure.com/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1/providers/Microsoft.PolicyInsights/remediations?$top=1&$filter=PolicyAssignmentId eq '/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/providers/microsoft.authorization/policyassignments/b101830944f246d8a14088c5'&api-version=2021-10-01
import com.azure.core.util.Context;
/** Samples for Remediations ListForResource. */
public final class Main {
/*
* x-ms-original-file: specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope_WithQuery.json
*/
/**
* Sample code: List remediations at individual resource scope with query parameters.
*
* @param manager Entry point to PolicyInsightsManager.
*/
public static void listRemediationsAtIndividualResourceScopeWithQueryParameters(
com.azure.resourcemanager.policyinsights.PolicyInsightsManager manager) {
manager
.remediations()
.listForResource(
"subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1",
1,
"PolicyAssignmentId eq"
+ " '/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/providers/microsoft.authorization/policyassignments/b101830944f246d8a14088c5'",
Context.NONE);
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.policyinsights import PolicyInsightsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-policyinsights
# USAGE
python remediations_list_resource_scope_with_query.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = PolicyInsightsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.remediations.list_for_resource(
resource_id="subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1",
)
for item in response:
print(item)
# x-ms-original-file: specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope_WithQuery.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armpolicyinsights_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/policyinsights/armpolicyinsights"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/05a9cdab363b8ec824094ee73950c04594325172/specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope_WithQuery.json
func ExampleRemediationsClient_NewListForResourcePager_listRemediationsAtIndividualResourceScopeWithQueryParameters() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armpolicyinsights.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewRemediationsClient().NewListForResourcePager("subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1", &armpolicyinsights.QueryOptions{Top: to.Ptr[int32](1),
Filter: to.Ptr("PolicyAssignmentId eq '/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/providers/microsoft.authorization/policyassignments/b101830944f246d8a14088c5'"),
OrderBy: nil,
Select: nil,
From: nil,
To: nil,
Apply: nil,
SkipToken: nil,
Expand: nil,
}, nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.RemediationListResult = armpolicyinsights.RemediationListResult{
// Value: []*armpolicyinsights.Remediation{
// {
// Name: to.Ptr("790996e6-9871-4b1f-9cd9-ec42cd6ced1e"),
// Type: to.Ptr("Microsoft.PolicyInsights/remediations"),
// ID: to.Ptr("/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1/providers/microsoft.policyinsights/remediations/790996e6-9871-4b1f-9cd9-ec42cd6ced1e"),
// Properties: &armpolicyinsights.RemediationProperties{
// CorrelationID: to.Ptr("a14e1d60-dae9-4771-b4be-a556d69e77a6"),
// CreatedOn: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-09-13T21:51:09.075Z"); return t}()),
// DeploymentStatus: &armpolicyinsights.RemediationDeploymentSummary{
// FailedDeployments: to.Ptr[int32](0),
// SuccessfulDeployments: to.Ptr[int32](1),
// TotalDeployments: to.Ptr[int32](1),
// },
// FailureThreshold: &armpolicyinsights.RemediationPropertiesFailureThreshold{
// Percentage: to.Ptr[float32](0.1),
// },
// LastUpdatedOn: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-09-13T21:52:10.001Z"); return t}()),
// ParallelDeployments: to.Ptr[int32](6),
// PolicyAssignmentID: to.Ptr("/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/providers/microsoft.authorization/policyassignments/b101830944f246d8a14088c5"),
// ProvisioningState: to.Ptr("Succeeded"),
// ResourceCount: to.Ptr[int32](42),
// ResourceDiscoveryMode: to.Ptr(armpolicyinsights.ResourceDiscoveryModeExistingNonCompliant),
// StatusMessage: to.Ptr("Remediation extended status"),
// },
// SystemData: &armpolicyinsights.SystemData{
// CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-09-13T21:51:09.075Z"); return t}()),
// CreatedBy: to.Ptr("b69a9388-9488-4534-b470-7ec6d41beef6"),
// CreatedByType: to.Ptr(armpolicyinsights.CreatedByTypeUser),
// LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-09-13T21:52:10.001Z"); return t}()),
// LastModifiedBy: to.Ptr("b69a9388-9488-4534-b470-7ec6d41beef6"),
// LastModifiedByType: to.Ptr(armpolicyinsights.CreatedByTypeUser),
// },
// }},
// }
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { PolicyInsightsClient } = require("@azure/arm-policyinsights");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to Gets all remediations for a resource.
*
* @summary Gets all remediations for a resource.
* x-ms-original-file: specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope_WithQuery.json
*/
async function listRemediationsAtIndividualResourceScopeWithQueryParameters() {
const subscriptionId =
process.env["POLICYINSIGHTS_SUBSCRIPTION_ID"] || "00000000-0000-0000-0000-000000000000";
const resourceId =
"subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1";
const top = 1;
const filter =
"PolicyAssignmentId eq '/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/providers/microsoft.authorization/policyassignments/b101830944f246d8a14088c5'";
const options = { queryOptions: { top: top, filter: filter } };
const credential = new DefaultAzureCredential();
const client = new PolicyInsightsClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.remediations.listForResource(resourceId, options)) {
resArray.push(item);
}
console.log(resArray);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
using System;
using System.Threading.Tasks;
using Azure;
using Azure.Core;
using Azure.Identity;
using Azure.ResourceManager;
using Azure.ResourceManager.PolicyInsights;
// Generated from example definition: specification/policyinsights/resource-manager/Microsoft.PolicyInsights/stable/2021-10-01/examples/Remediations_ListResourceScope_WithQuery.json
// this example is just showing the usage of "Remediations_ListForResource" operation, for the dependent resources, they will have to be created separately.
// get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line
TokenCredential cred = new DefaultAzureCredential();
// authenticate your client
ArmClient client = new ArmClient(cred);
// this example assumes you already have this ArmResource created on azure
// for more information of creating ArmResource, please refer to the document of ArmResource
// get the collection of this PolicyRemediationResource
string resourceId = "subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1";
ResourceIdentifier scopeId = new ResourceIdentifier(string.Format("/{0}", resourceId));
PolicyRemediationCollection collection = client.GetPolicyRemediations(scopeId);
// invoke the operation and iterate over the result
await foreach (PolicyRemediationResource item in collection.GetAllAsync())
{
// the variable item is a resource, you could call other operations on this instance as well
// but just for demo, we get its data from this resource instance
PolicyRemediationData resourceData = item.Data;
// for demo we just print out the id
Console.WriteLine($"Succeeded on id: {resourceData.Id}");
}
Console.WriteLine($"Succeeded");
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Sample Response
{
"value": [
{
"properties": {
"policyAssignmentId": "/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/providers/microsoft.authorization/policyassignments/b101830944f246d8a14088c5",
"provisioningState": "Succeeded",
"createdOn": "2018-09-13T21:51:09.075918Z",
"lastUpdatedOn": "2018-09-13T21:52:10.0011706Z",
"resourceDiscoveryMode": "ExistingNonCompliant",
"deploymentStatus": {
"totalDeployments": 1,
"successfulDeployments": 1,
"failedDeployments": 0
},
"statusMessage": "Remediation extended status",
"correlationId": "a14e1d60-dae9-4771-b4be-a556d69e77a6",
"resourceCount": 42,
"parallelDeployments": 6,
"failureThreshold": {
"percentage": 0.1
}
},
"id": "/subscriptions/35ee058e-5fa0-414c-8145-3ebb8d09b6e2/resourcegroups/myResourceGroup/providers/microsoft.storage/storageaccounts/storAc1/providers/microsoft.policyinsights/remediations/790996e6-9871-4b1f-9cd9-ec42cd6ced1e",
"name": "790996e6-9871-4b1f-9cd9-ec42cd6ced1e",
"type": "Microsoft.PolicyInsights/remediations",
"systemData": {
"createdBy": "b69a9388-9488-4534-b470-7ec6d41beef6",
"createdByType": "User",
"createdAt": "2018-09-13T21:51:09.075918Z",
"lastModifiedBy": "b69a9388-9488-4534-b470-7ec6d41beef6",
"lastModifiedByType": "User",
"lastModifiedAt": "2018-09-13T21:52:10.0011706Z"
}
}
]
}
Definities
createdByType
Het type identiteit waarmee de resource is gemaakt.
Name |
Type |
Description |
Application
|
string
|
|
Key
|
string
|
|
ManagedIdentity
|
string
|
|
User
|
string
|
|
ErrorDefinition
Foutdefinitie.
Name |
Type |
Description |
additionalInfo
|
TypedErrorInfo[]
|
Aanvullende scenariospecifieke foutdetails.
|
code
|
string
|
Servicespecifieke foutcode die fungeert als de substatus voor de HTTP-foutcode.
|
details
|
ErrorDefinition[]
|
Details van interne fouten.
|
message
|
string
|
Beschrijving van de fout.
|
target
|
string
|
Het doel van de fout.
|
ErrorResponse
Foutreactie.
FailureThreshold
De instellingen voor drempelwaarden voor herstelfouten
Name |
Type |
Description |
percentage
|
number
|
Een getal tussen 0,0 en 1,0 dat de drempelwaarde voor het foutpercentage vertegenwoordigt. Het herstel mislukt als het percentage mislukte herstelbewerkingen (d.w.w. mislukte implementaties) deze drempelwaarde overschrijdt.
|
De hersteldefinitie.
Name |
Type |
Description |
id
|
string
|
De id van het herstel.
|
name
|
string
|
De naam van het herstel.
|
properties.correlationId
|
string
|
De correlatie-id voor herstel. Kan worden gebruikt om gebeurtenissen te vinden die betrekking hebben op het herstel in het activiteitenlogboek.
|
properties.createdOn
|
string
|
Het tijdstip waarop het herstel is gemaakt.
|
properties.deploymentStatus
|
RemediationDeploymentSummary
|
Het overzicht van de implementatiestatus voor alle implementaties die door het herstel zijn gemaakt.
|
properties.failureThreshold
|
FailureThreshold
|
De instellingen voor drempelwaarden voor herstelfouten
|
properties.filters
|
RemediationFilters
|
De filters die worden toegepast om te bepalen welke resources moeten worden hersteld.
|
properties.lastUpdatedOn
|
string
|
Het tijdstip waarop het herstel voor het laatst is bijgewerkt.
|
properties.parallelDeployments
|
integer
|
Bepaalt hoeveel resources op een bepaald moment moeten worden hersteld. Kan worden gebruikt om het tempo van het herstel te verhogen of te verlagen. Als dit niet wordt opgegeven, wordt de standaardwaarde voor parallelle implementaties gebruikt.
|
properties.policyAssignmentId
|
string
|
De resource-id van de beleidstoewijzing die moet worden hersteld.
|
properties.policyDefinitionReferenceId
|
string
|
De referentie-id van de beleidsdefinitie van de afzonderlijke definitie die moet worden hersteld. Vereist wanneer de beleidstoewijzing die wordt hersteld, een definitie van een beleidsset toewijst.
|
properties.provisioningState
|
string
|
De status van het herstel. Dit verwijst naar de volledige hersteltaak, niet naar afzonderlijke implementaties. Toegestane waarden zijn Evalueren, Geannuleerd, Annuleren, Mislukt, Voltooid of Geslaagd.
|
properties.resourceCount
|
integer
|
Bepaalt het maximum aantal resources dat kan worden hersteld door de hersteltaak. Als dit niet wordt opgegeven, wordt het standaardaantal resources gebruikt.
|
properties.resourceDiscoveryMode
|
ResourceDiscoveryMode
|
De manier waarop resources worden gedetecteerd die moeten worden hersteld. De standaardinstelling is ExistingNonCompliant als dit niet is opgegeven.
|
properties.statusMessage
|
string
|
Het statusbericht voor herstel. Bevat aanvullende informatie over de status van het herstel.
|
systemData
|
systemData
|
Azure Resource Manager metagegevens met informatie over createdBy en modifiedBy.
|
type
|
string
|
Het type herstel.
|
Het overzicht van de implementatiestatus voor alle implementaties die door het herstel zijn gemaakt.
Name |
Type |
Description |
failedDeployments
|
integer
|
Het aantal implementaties dat is vereist voor het herstel dat is mislukt.
|
successfulDeployments
|
integer
|
Het aantal implementaties dat is vereist voor het herstel dat is geslaagd.
|
totalDeployments
|
integer
|
Het aantal implementaties dat is vereist voor het herstel.
|
De filters die worden toegepast om te bepalen welke resources moeten worden hersteld.
Name |
Type |
Description |
locations
|
string[]
|
De resourcelocaties die worden hersteld.
|
Lijst met herstelbewerkingen.
Name |
Type |
Description |
nextLink
|
string
|
De URL voor het ophalen van de volgende set resultaten.
|
value
|
Remediation[]
|
Matrix met hersteldefinities.
|
ResourceDiscoveryMode
De manier waarop resources worden gedetecteerd die moeten worden hersteld. De standaardinstelling is ExistingNonCompliant als dit niet is opgegeven.
Name |
Type |
Description |
ExistingNonCompliant
|
string
|
Herstel resources die al niet compatibel zijn.
|
ReEvaluateCompliance
|
string
|
Evalueer de nalevingsstatus van resources opnieuw en herstel vervolgens de resources die niet-compatibel zijn.
|
systemData
Metagegevens met betrekking tot het maken en laatste wijzigen van de resource.
Name |
Type |
Description |
createdAt
|
string
|
Het tijdstempel van het maken van resources (UTC).
|
createdBy
|
string
|
De identiteit waarmee de resource is gemaakt.
|
createdByType
|
createdByType
|
Het type identiteit waarmee de resource is gemaakt.
|
lastModifiedAt
|
string
|
De tijdstempel van de laatste wijziging van de resource (UTC)
|
lastModifiedBy
|
string
|
De identiteit die de resource het laatst heeft gewijzigd.
|
lastModifiedByType
|
createdByType
|
Het type identiteit dat de resource het laatst heeft gewijzigd.
|
TypedErrorInfo
Scenariospecifieke foutdetails.
Name |
Type |
Description |
info
|
|
De specifieke foutdetails van het scenario.
|
type
|
string
|
Het type opgenomen foutdetails.
|