ManagementPolicy
Manages an Azure Storage Account Management Policy.
Create a ManagementPolicy Resource
new ManagementPolicy(name: string, args: ManagementPolicyArgs, opts?: CustomResourceOptions);def ManagementPolicy(resource_name, opts=None, rules=None, storage_account_id=None, __props__=None);func NewManagementPolicy(ctx *Context, name string, args ManagementPolicyArgs, opts ...ResourceOption) (*ManagementPolicy, error)public ManagementPolicy(string name, ManagementPolicyArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args ManagementPolicyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ManagementPolicyArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ManagementPolicyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
ManagementPolicy Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The ManagementPolicy resource accepts the following input properties:
- Storage
Account stringId Specifies the id of the storage account to apply the management policy to.
- Rules
List<Management
Policy Rule Args> A
ruleblock as documented below.
- Storage
Account stringId Specifies the id of the storage account to apply the management policy to.
- Rules
[]Management
Policy Rule A
ruleblock as documented below.
- storage
Account stringId Specifies the id of the storage account to apply the management policy to.
- rules
Management
Policy Rule[] A
ruleblock as documented below.
- storage_
account_ strid Specifies the id of the storage account to apply the management policy to.
- rules
List[Management
Policy Rule] A
ruleblock as documented below.
Outputs
All input properties are implicitly available as output properties. Additionally, the ManagementPolicy resource produces the following output properties:
Look up an Existing ManagementPolicy Resource
Get an existing ManagementPolicy 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?: ManagementPolicyState, opts?: CustomResourceOptions): ManagementPolicystatic get(resource_name, id, opts=None, rules=None, storage_account_id=None, __props__=None);func GetManagementPolicy(ctx *Context, name string, id IDInput, state *ManagementPolicyState, opts ...ResourceOption) (*ManagementPolicy, error)public static ManagementPolicy Get(string name, Input<string> id, ManagementPolicyState? state, CustomResourceOptions? opts = null)- 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.
The following state arguments are supported:
- Rules
List<Management
Policy Rule Args> A
ruleblock as documented below.- Storage
Account stringId Specifies the id of the storage account to apply the management policy to.
- Rules
[]Management
Policy Rule A
ruleblock as documented below.- Storage
Account stringId Specifies the id of the storage account to apply the management policy to.
- rules
Management
Policy Rule[] A
ruleblock as documented below.- storage
Account stringId Specifies the id of the storage account to apply the management policy to.
- rules
List[Management
Policy Rule] A
ruleblock as documented below.- storage_
account_ strid Specifies the id of the storage account to apply the management policy to.
Supporting Types
ManagementPolicyRule
- Actions
Management
Policy Rule Actions Args An
actionsblock as documented below.- Enabled bool
Boolean to specify whether the rule is enabled.
- Name string
A rule name can contain any combination of alpha numeric characters. Rule name is case-sensitive. It must be unique within a policy.
- Filters
Management
Policy Rule Filters Args A
filterblock as documented below.
- Actions
Management
Policy Rule Actions An
actionsblock as documented below.- Enabled bool
Boolean to specify whether the rule is enabled.
- Name string
A rule name can contain any combination of alpha numeric characters. Rule name is case-sensitive. It must be unique within a policy.
- Filters
Management
Policy Rule Filters A
filterblock as documented below.
- actions
Management
Policy Rule Actions An
actionsblock as documented below.- enabled boolean
Boolean to specify whether the rule is enabled.
- name string
A rule name can contain any combination of alpha numeric characters. Rule name is case-sensitive. It must be unique within a policy.
- filters
Management
Policy Rule Filters A
filterblock as documented below.
- actions
Dict[Management
Policy Rule Actions] An
actionsblock as documented below.- enabled bool
Boolean to specify whether the rule is enabled.
- name str
A rule name can contain any combination of alpha numeric characters. Rule name is case-sensitive. It must be unique within a policy.
- filters
Dict[Management
Policy Rule Filters] A
filterblock as documented below.
ManagementPolicyRuleActions
- Base
Blob ManagementPolicy Rule Actions Base Blob Args A
base_blobblock as documented below.- Snapshot
Management
Policy Rule Actions Snapshot Args A
snapshotblock as documented below.
- Base
Blob ManagementPolicy Rule Actions Base Blob A
base_blobblock as documented below.- Snapshot
Management
Policy Rule Actions Snapshot A
snapshotblock as documented below.
- base
Blob ManagementPolicy Rule Actions Base Blob A
base_blobblock as documented below.- snapshot
Management
Policy Rule Actions Snapshot A
snapshotblock as documented below.
- base
Blob Dict[ManagementPolicy Rule Actions Base Blob] A
base_blobblock as documented below.- snapshot
Dict[Management
Policy Rule Actions Snapshot] A
snapshotblock as documented below.
ManagementPolicyRuleActionsBaseBlob
- Delete
After intDays Since Modification Greater Than The age in days after last modification to delete the blob. Must be at least 0.
- Tier
To intArchive After Days Since Modification Greater Than The age in days after last modification to tier blobs to archive storage. Supports blob currently at Hot or Cool tier. Must be at least 0.
- Tier
To intCool After Days Since Modification Greater Than The age in days after last modification to tier blobs to cool storage. Supports blob currently at Hot tier. Must be at least 0.
- Delete
After intDays Since Modification Greater Than The age in days after last modification to delete the blob. Must be at least 0.
- Tier
To intArchive After Days Since Modification Greater Than The age in days after last modification to tier blobs to archive storage. Supports blob currently at Hot or Cool tier. Must be at least 0.
- Tier
To intCool After Days Since Modification Greater Than The age in days after last modification to tier blobs to cool storage. Supports blob currently at Hot tier. Must be at least 0.
- delete
After numberDays Since Modification Greater Than The age in days after last modification to delete the blob. Must be at least 0.
- tier
To numberArchive After Days Since Modification Greater Than The age in days after last modification to tier blobs to archive storage. Supports blob currently at Hot or Cool tier. Must be at least 0.
- tier
To numberCool After Days Since Modification Greater Than The age in days after last modification to tier blobs to cool storage. Supports blob currently at Hot tier. Must be at least 0.
- delete
After floatDays Since Modification Greater Than The age in days after last modification to delete the blob. Must be at least 0.
- tier
To floatArchive After Days Since Modification Greater Than The age in days after last modification to tier blobs to archive storage. Supports blob currently at Hot or Cool tier. Must be at least 0.
- tier
To floatCool After Days Since Modification Greater Than The age in days after last modification to tier blobs to cool storage. Supports blob currently at Hot tier. Must be at least 0.
ManagementPolicyRuleActionsSnapshot
- Delete
After intDays Since Creation Greater Than The age in days after create to delete the snaphot. Must be at least 0.
- Delete
After intDays Since Creation Greater Than The age in days after create to delete the snaphot. Must be at least 0.
- delete
After numberDays Since Creation Greater Than The age in days after create to delete the snaphot. Must be at least 0.
- delete
After floatDays Since Creation Greater Than The age in days after create to delete the snaphot. Must be at least 0.
ManagementPolicyRuleFilters
- Blob
Types List<string> An array of predefined values. Only
blockBlobis supported.- Prefix
Matches List<string> An array of strings for prefixes to be matched.
- Blob
Types []string An array of predefined values. Only
blockBlobis supported.- Prefix
Matches []string An array of strings for prefixes to be matched.
- blob
Types string[] An array of predefined values. Only
blockBlobis supported.- prefix
Matches string[] An array of strings for prefixes to be matched.
- blob
Types List[str] An array of predefined values. Only
blockBlobis supported.- prefix
Matches List[str] An array of strings for prefixes to be matched.
Package Details
- Repository
- https://github.com/pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurermTerraform Provider.