crossplane-contrib / provider-jet-azure

Apache License 2.0
17 stars 20 forks source link

exclude RoleDefinitionID and RoleDefinitionName from RoleAssignment l… #201

Open ctkeyser opened 1 year ago

ctkeyser commented 1 year ago

this fixes a similar issue to the one described here https://github.com/crossplane-contrib/provider-jet-azure/issues/106 and fixed here https://github.com/crossplane-contrib/provider-jet-azure/pull/107

when creating a RoleAssignment and filling in either roleDefinitionId or roleDefinitionName, the opposite field is automatically filled in and results in the error

Warning  CannotObserveExternalResource  25s (x3 over 34s)  managed/authorization.azure.jet.crossplane.io/v1alpha1, kind=roleassignment  cannot run refresh: refresh failed: Conflicting configuration arguments: "role_definition_id": conflicts with role_definition_name: File name: main.tf.json
Conflicting configuration arguments: "role_definition_name": conflicts with role_definition_id: File name: main.tf.json

i would have opened against main branch, but the roleassignment files are missing there (this one for example https://github.com/crossplane-contrib/provider-jet-azure/blob/release-0.12-preview/apis/authorization/v1alpha1/zz_roleassignment_types.go). hopefully it's ok to open against this branch