-
Notifications
You must be signed in to change notification settings - Fork 4.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
azurerm_role_management_policy
New resource & data source
#25900
Open
oWretch
wants to merge
6
commits into
hashicorp:main
Choose a base branch
from
oWretch:f/pim-policies
base: main
Could not load branches
Branch not found: {{ refName }}
Could not load tags
Nothing to show
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
github-actions
bot
added
dependencies
service/authorization
size/XL
waiting-response
labels
May 8, 2024
manicminer
requested changes
May 9, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
internal/services/authorization/parse/role_management_policy.go
Outdated
Show resolved
Hide resolved
internal/services/authorization/role_management_policy_data_source.go
Outdated
Show resolved
Hide resolved
Func: func(ctx context.Context, metadata sdk.ResourceMetaData) error { | ||
client := metadata.Client.Authorization.RoleManagementPoliciesClient | ||
|
||
var id *parse.RoleManagementPolicyId |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As above, we can use the ID type from the sdk here
internal/services/authorization/role_management_policy_data_source.go
Outdated
Show resolved
Hide resolved
Comment on lines
579
to
588
Computed: true, | ||
}, | ||
"default_recipients": { | ||
Description: "Whether the default recipients are notified", | ||
Type: pluginsdk.TypeBool, | ||
Computed: true, | ||
}, | ||
"additional_recipients": { | ||
Description: "The additional recipients to notify", | ||
Type: pluginsdk.TypeSet, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and these
internal/services/authorization/role_management_policy_data_source.go
Outdated
Show resolved
Hide resolved
internal/services/authorization/role_management_policy_data_source.go
Outdated
Show resolved
Hide resolved
internal/services/authorization/role_management_policy_resource.go
Outdated
Show resolved
Hide resolved
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Community Note
Description
Add support for managing the policies for PIM assignments to Azure resources. Based on the work in hashicorp/terraform-provider-azuread#1327.
Closes #23295 as this has not been updated for 7 months and has merge conflicts with main. I also thought code consistency would be nice between providers. Also closes #20496.
Fixes #19912, fixes #22766, fixes #23458, fixes hashicorp/terraform-provider-azuread#1186
PR Checklist
Changes to existing Resource / Data Source
Testing
Change Log
Below please provide what should go into the changelog (if anything) conforming to the Changelog Format documented here.
azurerm_role_management_policy
- new resource [azurerm_role_management_policy
New resource & data source #25900]azurerm_role_management_policy
- new data source [azurerm_role_management_policy
New resource & data source #25900]This is a (please select all that apply):