Skip to content

Commit

Permalink
Proof of concept
Browse files Browse the repository at this point in the history
  • Loading branch information
alexwilcox9 committed Jun 18, 2023
1 parent debc250 commit 000afd3
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 4 deletions.
2 changes: 2 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,5 @@ require (
)

go 1.19

replace github.com/manicminer/hamilton => /home/alexwilcox/go/src/github.com/manicminer/hamilton
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,17 @@ func accessPackageResourcePackageAssociationResourceRead(ctx context.Context, d
}

func accessPackageResourcePackageAssociationResourceDelete(ctx context.Context, d *schema.ResourceData, meta interface{}) diag.Diagnostics {
log.Printf("[WARN] azuread_access_package_resource_package_association with ID %q must be manually deleted as there is no valid API provided for this operation", d.Id())
client := meta.(*clients.Client).IdentityGovernance.AccessPackageResourceRoleScopeClient

id, err := parse.AccessPackageResourcePackageAssociationID(d.Id())
if err != nil {
return tf.ErrorDiagPathF(err, "id", "Failed to parse resource ID %q", d.Id())
}

status, err := client.Delete(ctx, id.AccessPackageId, id.ResourcePackageAssociationId)
if err != nil {
return tf.ErrorDiagPathF(err, "id", "Deleting access package resource association with object ID %q, got status %d", id.ResourcePackageAssociationId, status)
}

return nil
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ github.com/hashicorp/terraform-svchost
# github.com/hashicorp/yamux v0.0.0-20211028200310-0bc27b27de87
## explicit; go 1.15
github.com/hashicorp/yamux
# github.com/manicminer/hamilton v0.61.0
# github.com/manicminer/hamilton v0.61.0 => /home/alexwilcox/go/src/github.com/manicminer/hamilton
## explicit; go 1.16
github.com/manicminer/hamilton/errors
github.com/manicminer/hamilton/internal/utils
Expand Down Expand Up @@ -374,3 +374,4 @@ google.golang.org/protobuf/types/known/timestamppb
## explicit; go 1.15
software.sslmate.com/src/go-pkcs12
software.sslmate.com/src/go-pkcs12/internal/rc2
# github.com/manicminer/hamilton => /home/alexwilcox/go/src/github.com/manicminer/hamilton

0 comments on commit 000afd3

Please sign in to comment.