We recommend using Azure Native.
azure.core.ResourceGroupPolicyRemediation
Explore with Pulumi AI
Manages an Azure Resource Group Policy Remediation.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = new azure.core.ResourceGroup("example", {
name: "example-resources",
location: "West Europe",
});
const exampleDefinition = new azure.policy.Definition("example", {
name: "my-policy-definition",
policyType: "Custom",
mode: "All",
displayName: "my-policy-definition",
policyRule: ` {
"if": {
"not": {
"field": "location",
"in": "[parameters('allowedLocations')]"
}
},
"then": {
"effect": "audit"
}
}
`,
parameters: ` {
"allowedLocations": {
"type": "Array",
"metadata": {
"description": "The list of allowed locations for resources.",
"displayName": "Allowed locations",
"strongType": "location"
}
}
}
`,
});
const exampleResourceGroupPolicyAssignment = new azure.core.ResourceGroupPolicyAssignment("example", {
name: "example",
resourceGroupId: example.id,
policyDefinitionId: exampleDefinition.id,
});
const exampleResourceGroupPolicyRemediation = new azure.core.ResourceGroupPolicyRemediation("example", {
name: "example-policy-remediation",
resourceGroupId: example.id,
policyAssignmentId: exampleResourceGroupPolicyAssignment.id,
locationFilters: ["West Europe"],
});
import pulumi
import pulumi_azure as azure
example = azure.core.ResourceGroup("example",
name="example-resources",
location="West Europe")
example_definition = azure.policy.Definition("example",
name="my-policy-definition",
policy_type="Custom",
mode="All",
display_name="my-policy-definition",
policy_rule=""" {
"if": {
"not": {
"field": "location",
"in": "[parameters('allowedLocations')]"
}
},
"then": {
"effect": "audit"
}
}
""",
parameters=""" {
"allowedLocations": {
"type": "Array",
"metadata": {
"description": "The list of allowed locations for resources.",
"displayName": "Allowed locations",
"strongType": "location"
}
}
}
""")
example_resource_group_policy_assignment = azure.core.ResourceGroupPolicyAssignment("example",
name="example",
resource_group_id=example.id,
policy_definition_id=example_definition.id)
example_resource_group_policy_remediation = azure.core.ResourceGroupPolicyRemediation("example",
name="example-policy-remediation",
resource_group_id=example.id,
policy_assignment_id=example_resource_group_policy_assignment.id,
location_filters=["West Europe"])
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/core"
"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/policy"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
Name: pulumi.String("example-resources"),
Location: pulumi.String("West Europe"),
})
if err != nil {
return err
}
exampleDefinition, err := policy.NewDefinition(ctx, "example", &policy.DefinitionArgs{
Name: pulumi.String("my-policy-definition"),
PolicyType: pulumi.String("Custom"),
Mode: pulumi.String("All"),
DisplayName: pulumi.String("my-policy-definition"),
PolicyRule: pulumi.String(` {
"if": {
"not": {
"field": "location",
"in": "[parameters('allowedLocations')]"
}
},
"then": {
"effect": "audit"
}
}
`),
Parameters: pulumi.String(` {
"allowedLocations": {
"type": "Array",
"metadata": {
"description": "The list of allowed locations for resources.",
"displayName": "Allowed locations",
"strongType": "location"
}
}
}
`),
})
if err != nil {
return err
}
exampleResourceGroupPolicyAssignment, err := core.NewResourceGroupPolicyAssignment(ctx, "example", &core.ResourceGroupPolicyAssignmentArgs{
Name: pulumi.String("example"),
ResourceGroupId: example.ID(),
PolicyDefinitionId: exampleDefinition.ID(),
})
if err != nil {
return err
}
_, err = core.NewResourceGroupPolicyRemediation(ctx, "example", &core.ResourceGroupPolicyRemediationArgs{
Name: pulumi.String("example-policy-remediation"),
ResourceGroupId: example.ID(),
PolicyAssignmentId: exampleResourceGroupPolicyAssignment.ID(),
LocationFilters: pulumi.StringArray{
pulumi.String("West Europe"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = new Azure.Core.ResourceGroup("example", new()
{
Name = "example-resources",
Location = "West Europe",
});
var exampleDefinition = new Azure.Policy.Definition("example", new()
{
Name = "my-policy-definition",
PolicyType = "Custom",
Mode = "All",
DisplayName = "my-policy-definition",
PolicyRule = @" {
""if"": {
""not"": {
""field"": ""location"",
""in"": ""[parameters('allowedLocations')]""
}
},
""then"": {
""effect"": ""audit""
}
}
",
Parameters = @" {
""allowedLocations"": {
""type"": ""Array"",
""metadata"": {
""description"": ""The list of allowed locations for resources."",
""displayName"": ""Allowed locations"",
""strongType"": ""location""
}
}
}
",
});
var exampleResourceGroupPolicyAssignment = new Azure.Core.ResourceGroupPolicyAssignment("example", new()
{
Name = "example",
ResourceGroupId = example.Id,
PolicyDefinitionId = exampleDefinition.Id,
});
var exampleResourceGroupPolicyRemediation = new Azure.Core.ResourceGroupPolicyRemediation("example", new()
{
Name = "example-policy-remediation",
ResourceGroupId = example.Id,
PolicyAssignmentId = exampleResourceGroupPolicyAssignment.Id,
LocationFilters = new[]
{
"West Europe",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.core.ResourceGroup;
import com.pulumi.azure.core.ResourceGroupArgs;
import com.pulumi.azure.policy.Definition;
import com.pulumi.azure.policy.DefinitionArgs;
import com.pulumi.azure.core.ResourceGroupPolicyAssignment;
import com.pulumi.azure.core.ResourceGroupPolicyAssignmentArgs;
import com.pulumi.azure.core.ResourceGroupPolicyRemediation;
import com.pulumi.azure.core.ResourceGroupPolicyRemediationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new ResourceGroup("example", ResourceGroupArgs.builder()
.name("example-resources")
.location("West Europe")
.build());
var exampleDefinition = new Definition("exampleDefinition", DefinitionArgs.builder()
.name("my-policy-definition")
.policyType("Custom")
.mode("All")
.displayName("my-policy-definition")
.policyRule("""
{
"if": {
"not": {
"field": "location",
"in": "[parameters('allowedLocations')]"
}
},
"then": {
"effect": "audit"
}
}
""")
.parameters("""
{
"allowedLocations": {
"type": "Array",
"metadata": {
"description": "The list of allowed locations for resources.",
"displayName": "Allowed locations",
"strongType": "location"
}
}
}
""")
.build());
var exampleResourceGroupPolicyAssignment = new ResourceGroupPolicyAssignment("exampleResourceGroupPolicyAssignment", ResourceGroupPolicyAssignmentArgs.builder()
.name("example")
.resourceGroupId(example.id())
.policyDefinitionId(exampleDefinition.id())
.build());
var exampleResourceGroupPolicyRemediation = new ResourceGroupPolicyRemediation("exampleResourceGroupPolicyRemediation", ResourceGroupPolicyRemediationArgs.builder()
.name("example-policy-remediation")
.resourceGroupId(example.id())
.policyAssignmentId(exampleResourceGroupPolicyAssignment.id())
.locationFilters("West Europe")
.build());
}
}
resources:
example:
type: azure:core:ResourceGroup
properties:
name: example-resources
location: West Europe
exampleDefinition:
type: azure:policy:Definition
name: example
properties:
name: my-policy-definition
policyType: Custom
mode: All
displayName: my-policy-definition
policyRule: |2
{
"if": {
"not": {
"field": "location",
"in": "[parameters('allowedLocations')]"
}
},
"then": {
"effect": "audit"
}
}
parameters: |2
{
"allowedLocations": {
"type": "Array",
"metadata": {
"description": "The list of allowed locations for resources.",
"displayName": "Allowed locations",
"strongType": "location"
}
}
}
exampleResourceGroupPolicyAssignment:
type: azure:core:ResourceGroupPolicyAssignment
name: example
properties:
name: example
resourceGroupId: ${example.id}
policyDefinitionId: ${exampleDefinition.id}
exampleResourceGroupPolicyRemediation:
type: azure:core:ResourceGroupPolicyRemediation
name: example
properties:
name: example-policy-remediation
resourceGroupId: ${example.id}
policyAssignmentId: ${exampleResourceGroupPolicyAssignment.id}
locationFilters:
- West Europe
Create ResourceGroupPolicyRemediation Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ResourceGroupPolicyRemediation(name: string, args: ResourceGroupPolicyRemediationArgs, opts?: CustomResourceOptions);
@overload
def ResourceGroupPolicyRemediation(resource_name: str,
args: ResourceGroupPolicyRemediationArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ResourceGroupPolicyRemediation(resource_name: str,
opts: Optional[ResourceOptions] = None,
policy_assignment_id: Optional[str] = None,
resource_group_id: Optional[str] = None,
failure_percentage: Optional[float] = None,
location_filters: Optional[Sequence[str]] = None,
name: Optional[str] = None,
parallel_deployments: Optional[int] = None,
policy_definition_reference_id: Optional[str] = None,
resource_count: Optional[int] = None,
resource_discovery_mode: Optional[str] = None)
func NewResourceGroupPolicyRemediation(ctx *Context, name string, args ResourceGroupPolicyRemediationArgs, opts ...ResourceOption) (*ResourceGroupPolicyRemediation, error)
public ResourceGroupPolicyRemediation(string name, ResourceGroupPolicyRemediationArgs args, CustomResourceOptions? opts = null)
public ResourceGroupPolicyRemediation(String name, ResourceGroupPolicyRemediationArgs args)
public ResourceGroupPolicyRemediation(String name, ResourceGroupPolicyRemediationArgs args, CustomResourceOptions options)
type: azure:core:ResourceGroupPolicyRemediation
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ResourceGroupPolicyRemediationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ResourceGroupPolicyRemediationArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ResourceGroupPolicyRemediationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ResourceGroupPolicyRemediationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ResourceGroupPolicyRemediationArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var resourceGroupPolicyRemediationResource = new Azure.Core.ResourceGroupPolicyRemediation("resourceGroupPolicyRemediationResource", new()
{
PolicyAssignmentId = "string",
ResourceGroupId = "string",
FailurePercentage = 0,
LocationFilters = new[]
{
"string",
},
Name = "string",
ParallelDeployments = 0,
PolicyDefinitionReferenceId = "string",
ResourceCount = 0,
ResourceDiscoveryMode = "string",
});
example, err := core.NewResourceGroupPolicyRemediation(ctx, "resourceGroupPolicyRemediationResource", &core.ResourceGroupPolicyRemediationArgs{
PolicyAssignmentId: pulumi.String("string"),
ResourceGroupId: pulumi.String("string"),
FailurePercentage: pulumi.Float64(0),
LocationFilters: pulumi.StringArray{
pulumi.String("string"),
},
Name: pulumi.String("string"),
ParallelDeployments: pulumi.Int(0),
PolicyDefinitionReferenceId: pulumi.String("string"),
ResourceCount: pulumi.Int(0),
ResourceDiscoveryMode: pulumi.String("string"),
})
var resourceGroupPolicyRemediationResource = new ResourceGroupPolicyRemediation("resourceGroupPolicyRemediationResource", ResourceGroupPolicyRemediationArgs.builder()
.policyAssignmentId("string")
.resourceGroupId("string")
.failurePercentage(0)
.locationFilters("string")
.name("string")
.parallelDeployments(0)
.policyDefinitionReferenceId("string")
.resourceCount(0)
.resourceDiscoveryMode("string")
.build());
resource_group_policy_remediation_resource = azure.core.ResourceGroupPolicyRemediation("resourceGroupPolicyRemediationResource",
policy_assignment_id="string",
resource_group_id="string",
failure_percentage=0,
location_filters=["string"],
name="string",
parallel_deployments=0,
policy_definition_reference_id="string",
resource_count=0,
resource_discovery_mode="string")
const resourceGroupPolicyRemediationResource = new azure.core.ResourceGroupPolicyRemediation("resourceGroupPolicyRemediationResource", {
policyAssignmentId: "string",
resourceGroupId: "string",
failurePercentage: 0,
locationFilters: ["string"],
name: "string",
parallelDeployments: 0,
policyDefinitionReferenceId: "string",
resourceCount: 0,
resourceDiscoveryMode: "string",
});
type: azure:core:ResourceGroupPolicyRemediation
properties:
failurePercentage: 0
locationFilters:
- string
name: string
parallelDeployments: 0
policyAssignmentId: string
policyDefinitionReferenceId: string
resourceCount: 0
resourceDiscoveryMode: string
resourceGroupId: string
ResourceGroupPolicyRemediation Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The ResourceGroupPolicyRemediation resource accepts the following input properties:
- Policy
Assignment stringId - The ID of the Policy Assignment that should be remediated.
- Resource
Group stringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- Failure
Percentage double - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- Location
Filters List<string> - A list of the resource locations that will be remediated.
- Name string
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- Parallel
Deployments int - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- Policy
Definition stringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- Resource
Count int - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- Resource
Discovery stringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
.
- Policy
Assignment stringId - The ID of the Policy Assignment that should be remediated.
- Resource
Group stringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- Failure
Percentage float64 - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- Location
Filters []string - A list of the resource locations that will be remediated.
- Name string
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- Parallel
Deployments int - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- Policy
Definition stringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- Resource
Count int - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- Resource
Discovery stringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
.
- policy
Assignment StringId - The ID of the Policy Assignment that should be remediated.
- resource
Group StringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- failure
Percentage Double - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- location
Filters List<String> - A list of the resource locations that will be remediated.
- name String
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- parallel
Deployments Integer - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- policy
Definition StringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- resource
Count Integer - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- resource
Discovery StringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
.
- policy
Assignment stringId - The ID of the Policy Assignment that should be remediated.
- resource
Group stringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- failure
Percentage number - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- location
Filters string[] - A list of the resource locations that will be remediated.
- name string
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- parallel
Deployments number - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- policy
Definition stringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- resource
Count number - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- resource
Discovery stringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
.
- policy_
assignment_ strid - The ID of the Policy Assignment that should be remediated.
- resource_
group_ strid - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- failure_
percentage float - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- location_
filters Sequence[str] - A list of the resource locations that will be remediated.
- name str
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- parallel_
deployments int - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- policy_
definition_ strreference_ id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- resource_
count int - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- resource_
discovery_ strmode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
.
- policy
Assignment StringId - The ID of the Policy Assignment that should be remediated.
- resource
Group StringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- failure
Percentage Number - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- location
Filters List<String> - A list of the resource locations that will be remediated.
- name String
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- parallel
Deployments Number - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- policy
Definition StringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- resource
Count Number - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- resource
Discovery StringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
.
Outputs
All input properties are implicitly available as output properties. Additionally, the ResourceGroupPolicyRemediation resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing ResourceGroupPolicyRemediation Resource
Get an existing ResourceGroupPolicyRemediation resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: ResourceGroupPolicyRemediationState, opts?: CustomResourceOptions): ResourceGroupPolicyRemediation
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
failure_percentage: Optional[float] = None,
location_filters: Optional[Sequence[str]] = None,
name: Optional[str] = None,
parallel_deployments: Optional[int] = None,
policy_assignment_id: Optional[str] = None,
policy_definition_reference_id: Optional[str] = None,
resource_count: Optional[int] = None,
resource_discovery_mode: Optional[str] = None,
resource_group_id: Optional[str] = None) -> ResourceGroupPolicyRemediation
func GetResourceGroupPolicyRemediation(ctx *Context, name string, id IDInput, state *ResourceGroupPolicyRemediationState, opts ...ResourceOption) (*ResourceGroupPolicyRemediation, error)
public static ResourceGroupPolicyRemediation Get(string name, Input<string> id, ResourceGroupPolicyRemediationState? state, CustomResourceOptions? opts = null)
public static ResourceGroupPolicyRemediation get(String name, Output<String> id, ResourceGroupPolicyRemediationState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Failure
Percentage double - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- Location
Filters List<string> - A list of the resource locations that will be remediated.
- Name string
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- Parallel
Deployments int - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- Policy
Assignment stringId - The ID of the Policy Assignment that should be remediated.
- Policy
Definition stringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- Resource
Count int - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- Resource
Discovery stringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
. - Resource
Group stringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- Failure
Percentage float64 - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- Location
Filters []string - A list of the resource locations that will be remediated.
- Name string
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- Parallel
Deployments int - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- Policy
Assignment stringId - The ID of the Policy Assignment that should be remediated.
- Policy
Definition stringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- Resource
Count int - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- Resource
Discovery stringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
. - Resource
Group stringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- failure
Percentage Double - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- location
Filters List<String> - A list of the resource locations that will be remediated.
- name String
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- parallel
Deployments Integer - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- policy
Assignment StringId - The ID of the Policy Assignment that should be remediated.
- policy
Definition StringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- resource
Count Integer - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- resource
Discovery StringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
. - resource
Group StringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- failure
Percentage number - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- location
Filters string[] - A list of the resource locations that will be remediated.
- name string
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- parallel
Deployments number - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- policy
Assignment stringId - The ID of the Policy Assignment that should be remediated.
- policy
Definition stringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- resource
Count number - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- resource
Discovery stringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
. - resource
Group stringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- failure_
percentage float - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- location_
filters Sequence[str] - A list of the resource locations that will be remediated.
- name str
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- parallel_
deployments int - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- policy_
assignment_ strid - The ID of the Policy Assignment that should be remediated.
- policy_
definition_ strreference_ id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- resource_
count int - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- resource_
discovery_ strmode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
. - resource_
group_ strid - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
- failure
Percentage Number - A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
- location
Filters List<String> - A list of the resource locations that will be remediated.
- name String
- The name of the Policy Remediation. Changing this forces a new resource to be created.
- parallel
Deployments Number - Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
- policy
Assignment StringId - The ID of the Policy Assignment that should be remediated.
- policy
Definition StringReference Id - The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
- resource
Count Number - Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
- resource
Discovery StringMode - The way that resources to remediate are discovered. Possible values are
ExistingNonCompliant
,ReEvaluateCompliance
. Defaults toExistingNonCompliant
. - resource
Group StringId - The Resource Group ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
Import
Policy Remediations can be imported using the resource id
, e.g.
$ pulumi import azure:core/resourceGroupPolicyRemediation:ResourceGroupPolicyRemediation example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.PolicyInsights/remediations/remediation1
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurerm
Terraform Provider.