We recommend using Azure Native.
azure.core.ResourceGroupPolicyExemption
Explore with Pulumi AI
Manages a Resource Group Policy Exemption.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const exampleResourceGroup = new azure.core.ResourceGroup("example", {
name: "resourceGroup1",
location: "westus",
});
const example = azure.policy.getPolicyDefintion({
displayName: "Allowed locations",
});
const exampleResourceGroupPolicyAssignment = new azure.core.ResourceGroupPolicyAssignment("example", {
name: "exampleAssignment",
resourceGroupId: exampleResourceGroup.id,
policyDefinitionId: example.then(example => example.id),
parameters: pulumi.jsonStringify({
listOfAllowedLocations: {
value: [exampleResourceGroup.location],
},
}),
});
const exampleResourceGroupPolicyExemption = new azure.core.ResourceGroupPolicyExemption("example", {
name: "exampleExemption",
resourceGroupId: exampleResourceGroup.id,
policyAssignmentId: exampleResourceGroupPolicyAssignment.id,
exemptionCategory: "Mitigated",
});
import pulumi
import json
import pulumi_azure as azure
example_resource_group = azure.core.ResourceGroup("example",
name="resourceGroup1",
location="westus")
example = azure.policy.get_policy_defintion(display_name="Allowed locations")
example_resource_group_policy_assignment = azure.core.ResourceGroupPolicyAssignment("example",
name="exampleAssignment",
resource_group_id=example_resource_group.id,
policy_definition_id=example.id,
parameters=pulumi.Output.json_dumps({
"listOfAllowedLocations": {
"value": [example_resource_group.location],
},
}))
example_resource_group_policy_exemption = azure.core.ResourceGroupPolicyExemption("example",
name="exampleExemption",
resource_group_id=example_resource_group.id,
policy_assignment_id=example_resource_group_policy_assignment.id,
exemption_category="Mitigated")
package main
import (
"encoding/json"
"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 {
exampleResourceGroup, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
Name: pulumi.String("resourceGroup1"),
Location: pulumi.String("westus"),
})
if err != nil {
return err
}
example, err := policy.GetPolicyDefintion(ctx, &policy.GetPolicyDefintionArgs{
DisplayName: pulumi.StringRef("Allowed locations"),
}, nil)
if err != nil {
return err
}
exampleResourceGroupPolicyAssignment, err := core.NewResourceGroupPolicyAssignment(ctx, "example", &core.ResourceGroupPolicyAssignmentArgs{
Name: pulumi.String("exampleAssignment"),
ResourceGroupId: exampleResourceGroup.ID(),
PolicyDefinitionId: pulumi.String(example.Id),
Parameters: exampleResourceGroup.Location.ApplyT(func(location string) (pulumi.String, error) {
var _zero pulumi.String
tmpJSON0, err := json.Marshal(map[string]interface{}{
"listOfAllowedLocations": map[string]interface{}{
"value": []string{
location,
},
},
})
if err != nil {
return _zero, err
}
json0 := string(tmpJSON0)
return pulumi.String(json0), nil
}).(pulumi.StringOutput),
})
if err != nil {
return err
}
_, err = core.NewResourceGroupPolicyExemption(ctx, "example", &core.ResourceGroupPolicyExemptionArgs{
Name: pulumi.String("exampleExemption"),
ResourceGroupId: exampleResourceGroup.ID(),
PolicyAssignmentId: exampleResourceGroupPolicyAssignment.ID(),
ExemptionCategory: pulumi.String("Mitigated"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using System.Text.Json;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var exampleResourceGroup = new Azure.Core.ResourceGroup("example", new()
{
Name = "resourceGroup1",
Location = "westus",
});
var example = Azure.Policy.GetPolicyDefintion.Invoke(new()
{
DisplayName = "Allowed locations",
});
var exampleResourceGroupPolicyAssignment = new Azure.Core.ResourceGroupPolicyAssignment("example", new()
{
Name = "exampleAssignment",
ResourceGroupId = exampleResourceGroup.Id,
PolicyDefinitionId = example.Apply(getPolicyDefintionResult => getPolicyDefintionResult.Id),
Parameters = Output.JsonSerialize(Output.Create(new Dictionary<string, object?>
{
["listOfAllowedLocations"] = new Dictionary<string, object?>
{
["value"] = new[]
{
exampleResourceGroup.Location,
},
},
})),
});
var exampleResourceGroupPolicyExemption = new Azure.Core.ResourceGroupPolicyExemption("example", new()
{
Name = "exampleExemption",
ResourceGroupId = exampleResourceGroup.Id,
PolicyAssignmentId = exampleResourceGroupPolicyAssignment.Id,
ExemptionCategory = "Mitigated",
});
});
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.PolicyFunctions;
import com.pulumi.azure.policy.inputs.GetPolicyDefintionArgs;
import com.pulumi.azure.core.ResourceGroupPolicyAssignment;
import com.pulumi.azure.core.ResourceGroupPolicyAssignmentArgs;
import com.pulumi.azure.core.ResourceGroupPolicyExemption;
import com.pulumi.azure.core.ResourceGroupPolicyExemptionArgs;
import static com.pulumi.codegen.internal.Serialization.*;
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 exampleResourceGroup = new ResourceGroup("exampleResourceGroup", ResourceGroupArgs.builder()
.name("resourceGroup1")
.location("westus")
.build());
final var example = PolicyFunctions.getPolicyDefintion(GetPolicyDefintionArgs.builder()
.displayName("Allowed locations")
.build());
var exampleResourceGroupPolicyAssignment = new ResourceGroupPolicyAssignment("exampleResourceGroupPolicyAssignment", ResourceGroupPolicyAssignmentArgs.builder()
.name("exampleAssignment")
.resourceGroupId(exampleResourceGroup.id())
.policyDefinitionId(example.applyValue(getPolicyDefintionResult -> getPolicyDefintionResult.id()))
.parameters(exampleResourceGroup.location().applyValue(location -> serializeJson(
jsonObject(
jsonProperty("listOfAllowedLocations", jsonObject(
jsonProperty("value", jsonArray(location))
))
))))
.build());
var exampleResourceGroupPolicyExemption = new ResourceGroupPolicyExemption("exampleResourceGroupPolicyExemption", ResourceGroupPolicyExemptionArgs.builder()
.name("exampleExemption")
.resourceGroupId(exampleResourceGroup.id())
.policyAssignmentId(exampleResourceGroupPolicyAssignment.id())
.exemptionCategory("Mitigated")
.build());
}
}
resources:
exampleResourceGroup:
type: azure:core:ResourceGroup
name: example
properties:
name: resourceGroup1
location: westus
exampleResourceGroupPolicyAssignment:
type: azure:core:ResourceGroupPolicyAssignment
name: example
properties:
name: exampleAssignment
resourceGroupId: ${exampleResourceGroup.id}
policyDefinitionId: ${example.id}
parameters:
fn::toJSON:
listOfAllowedLocations:
value:
- ${exampleResourceGroup.location}
exampleResourceGroupPolicyExemption:
type: azure:core:ResourceGroupPolicyExemption
name: example
properties:
name: exampleExemption
resourceGroupId: ${exampleResourceGroup.id}
policyAssignmentId: ${exampleResourceGroupPolicyAssignment.id}
exemptionCategory: Mitigated
variables:
example:
fn::invoke:
Function: azure:policy:getPolicyDefintion
Arguments:
displayName: Allowed locations
Create ResourceGroupPolicyExemption Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ResourceGroupPolicyExemption(name: string, args: ResourceGroupPolicyExemptionArgs, opts?: CustomResourceOptions);
@overload
def ResourceGroupPolicyExemption(resource_name: str,
args: ResourceGroupPolicyExemptionArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ResourceGroupPolicyExemption(resource_name: str,
opts: Optional[ResourceOptions] = None,
exemption_category: Optional[str] = None,
policy_assignment_id: Optional[str] = None,
resource_group_id: Optional[str] = None,
description: Optional[str] = None,
display_name: Optional[str] = None,
expires_on: Optional[str] = None,
metadata: Optional[str] = None,
name: Optional[str] = None,
policy_definition_reference_ids: Optional[Sequence[str]] = None)
func NewResourceGroupPolicyExemption(ctx *Context, name string, args ResourceGroupPolicyExemptionArgs, opts ...ResourceOption) (*ResourceGroupPolicyExemption, error)
public ResourceGroupPolicyExemption(string name, ResourceGroupPolicyExemptionArgs args, CustomResourceOptions? opts = null)
public ResourceGroupPolicyExemption(String name, ResourceGroupPolicyExemptionArgs args)
public ResourceGroupPolicyExemption(String name, ResourceGroupPolicyExemptionArgs args, CustomResourceOptions options)
type: azure:core:ResourceGroupPolicyExemption
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 ResourceGroupPolicyExemptionArgs
- 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 ResourceGroupPolicyExemptionArgs
- 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 ResourceGroupPolicyExemptionArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ResourceGroupPolicyExemptionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ResourceGroupPolicyExemptionArgs
- 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 resourceGroupPolicyExemptionResource = new Azure.Core.ResourceGroupPolicyExemption("resourceGroupPolicyExemptionResource", new()
{
ExemptionCategory = "string",
PolicyAssignmentId = "string",
ResourceGroupId = "string",
Description = "string",
DisplayName = "string",
ExpiresOn = "string",
Metadata = "string",
Name = "string",
PolicyDefinitionReferenceIds = new[]
{
"string",
},
});
example, err := core.NewResourceGroupPolicyExemption(ctx, "resourceGroupPolicyExemptionResource", &core.ResourceGroupPolicyExemptionArgs{
ExemptionCategory: pulumi.String("string"),
PolicyAssignmentId: pulumi.String("string"),
ResourceGroupId: pulumi.String("string"),
Description: pulumi.String("string"),
DisplayName: pulumi.String("string"),
ExpiresOn: pulumi.String("string"),
Metadata: pulumi.String("string"),
Name: pulumi.String("string"),
PolicyDefinitionReferenceIds: pulumi.StringArray{
pulumi.String("string"),
},
})
var resourceGroupPolicyExemptionResource = new ResourceGroupPolicyExemption("resourceGroupPolicyExemptionResource", ResourceGroupPolicyExemptionArgs.builder()
.exemptionCategory("string")
.policyAssignmentId("string")
.resourceGroupId("string")
.description("string")
.displayName("string")
.expiresOn("string")
.metadata("string")
.name("string")
.policyDefinitionReferenceIds("string")
.build());
resource_group_policy_exemption_resource = azure.core.ResourceGroupPolicyExemption("resourceGroupPolicyExemptionResource",
exemption_category="string",
policy_assignment_id="string",
resource_group_id="string",
description="string",
display_name="string",
expires_on="string",
metadata="string",
name="string",
policy_definition_reference_ids=["string"])
const resourceGroupPolicyExemptionResource = new azure.core.ResourceGroupPolicyExemption("resourceGroupPolicyExemptionResource", {
exemptionCategory: "string",
policyAssignmentId: "string",
resourceGroupId: "string",
description: "string",
displayName: "string",
expiresOn: "string",
metadata: "string",
name: "string",
policyDefinitionReferenceIds: ["string"],
});
type: azure:core:ResourceGroupPolicyExemption
properties:
description: string
displayName: string
exemptionCategory: string
expiresOn: string
metadata: string
name: string
policyAssignmentId: string
policyDefinitionReferenceIds:
- string
resourceGroupId: string
ResourceGroupPolicyExemption 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 ResourceGroupPolicyExemption resource accepts the following input properties:
- Exemption
Category string - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - Policy
Assignment stringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- Resource
Group stringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- Description string
- A description to use for this Policy Exemption.
- Display
Name string - A friendly display name to use for this Policy Exemption.
- Expires
On string - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- Metadata string
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- Name string
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- Policy
Definition List<string>Reference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- Exemption
Category string - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - Policy
Assignment stringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- Resource
Group stringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- Description string
- A description to use for this Policy Exemption.
- Display
Name string - A friendly display name to use for this Policy Exemption.
- Expires
On string - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- Metadata string
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- Name string
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- Policy
Definition []stringReference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- exemption
Category String - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - policy
Assignment StringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- resource
Group StringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- description String
- A description to use for this Policy Exemption.
- display
Name String - A friendly display name to use for this Policy Exemption.
- expires
On String - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- metadata String
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- name String
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- policy
Definition List<String>Reference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- exemption
Category string - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - policy
Assignment stringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- resource
Group stringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- description string
- A description to use for this Policy Exemption.
- display
Name string - A friendly display name to use for this Policy Exemption.
- expires
On string - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- metadata string
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- name string
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- policy
Definition string[]Reference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- exemption_
category str - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - policy_
assignment_ strid - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- resource_
group_ strid - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- description str
- A description to use for this Policy Exemption.
- display_
name str - A friendly display name to use for this Policy Exemption.
- expires_
on str - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- metadata str
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- name str
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- policy_
definition_ Sequence[str]reference_ ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- exemption
Category String - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - policy
Assignment StringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- resource
Group StringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- description String
- A description to use for this Policy Exemption.
- display
Name String - A friendly display name to use for this Policy Exemption.
- expires
On String - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- metadata String
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- name String
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- policy
Definition List<String>Reference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
Outputs
All input properties are implicitly available as output properties. Additionally, the ResourceGroupPolicyExemption 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 ResourceGroupPolicyExemption Resource
Get an existing ResourceGroupPolicyExemption 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?: ResourceGroupPolicyExemptionState, opts?: CustomResourceOptions): ResourceGroupPolicyExemption
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
display_name: Optional[str] = None,
exemption_category: Optional[str] = None,
expires_on: Optional[str] = None,
metadata: Optional[str] = None,
name: Optional[str] = None,
policy_assignment_id: Optional[str] = None,
policy_definition_reference_ids: Optional[Sequence[str]] = None,
resource_group_id: Optional[str] = None) -> ResourceGroupPolicyExemption
func GetResourceGroupPolicyExemption(ctx *Context, name string, id IDInput, state *ResourceGroupPolicyExemptionState, opts ...ResourceOption) (*ResourceGroupPolicyExemption, error)
public static ResourceGroupPolicyExemption Get(string name, Input<string> id, ResourceGroupPolicyExemptionState? state, CustomResourceOptions? opts = null)
public static ResourceGroupPolicyExemption get(String name, Output<String> id, ResourceGroupPolicyExemptionState 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.
- Description string
- A description to use for this Policy Exemption.
- Display
Name string - A friendly display name to use for this Policy Exemption.
- Exemption
Category string - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - Expires
On string - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- Metadata string
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- Name string
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- Policy
Assignment stringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- Policy
Definition List<string>Reference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- Resource
Group stringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- Description string
- A description to use for this Policy Exemption.
- Display
Name string - A friendly display name to use for this Policy Exemption.
- Exemption
Category string - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - Expires
On string - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- Metadata string
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- Name string
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- Policy
Assignment stringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- Policy
Definition []stringReference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- Resource
Group stringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- description String
- A description to use for this Policy Exemption.
- display
Name String - A friendly display name to use for this Policy Exemption.
- exemption
Category String - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - expires
On String - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- metadata String
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- name String
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- policy
Assignment StringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- policy
Definition List<String>Reference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- resource
Group StringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- description string
- A description to use for this Policy Exemption.
- display
Name string - A friendly display name to use for this Policy Exemption.
- exemption
Category string - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - expires
On string - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- metadata string
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- name string
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- policy
Assignment stringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- policy
Definition string[]Reference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- resource
Group stringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- description str
- A description to use for this Policy Exemption.
- display_
name str - A friendly display name to use for this Policy Exemption.
- exemption_
category str - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - expires_
on str - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- metadata str
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- name str
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- policy_
assignment_ strid - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- policy_
definition_ Sequence[str]reference_ ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- resource_
group_ strid - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
- description String
- A description to use for this Policy Exemption.
- display
Name String - A friendly display name to use for this Policy Exemption.
- exemption
Category String - The category of this policy exemption. Possible values are
Waiver
andMitigated
. - expires
On String - The expiration date and time in UTC ISO 8601 format of this policy exemption.
- metadata String
- The metadata for this policy exemption. This is a JSON string representing additional metadata that should be stored with the policy exemption.
- name String
- The name of the Policy Exemption. Changing this forces a new resource to be created.
- policy
Assignment StringId - The ID of the Policy Assignment to be exempted at the specified Scope. Changing this forces a new resource to be created.
- policy
Definition List<String>Reference Ids - The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition.
- resource
Group StringId - The Resource Group ID where the Policy Exemption should be applied. Changing this forces a new resource to be created.
Import
Policy Exemptions can be imported using the resource id
, e.g.
$ pulumi import azure:core/resourceGroupPolicyExemption:ResourceGroupPolicyExemption exemption1 /subscriptions/00000000-0000-0000-000000000000/resourceGroups/resGroup1/providers/Microsoft.Authorization/policyExemptions/exemption1
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.