-
Notifications
You must be signed in to change notification settings - Fork 151
/
getResource.go
58 lines (53 loc) · 1.68 KB
/
getResource.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package lakeformation
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Provides details about a Lake Formation resource.
//
// ## Example Usage
//
// ```go
// package main
//
// import (
// "github.com/pulumi/pulumi-aws/sdk/v4/go/aws/lakeformation"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// _, err := lakeformation.LookupResource(ctx, &lakeformation.LookupResourceArgs{
// Arn: "arn:aws:s3:::tf-acc-test-9151654063908211878",
// }, nil)
// if err != nil {
// return err
// }
// return nil
// })
// }
// ```
func LookupResource(ctx *pulumi.Context, args *LookupResourceArgs, opts ...pulumi.InvokeOption) (*LookupResourceResult, error) {
var rv LookupResourceResult
err := ctx.Invoke("aws:lakeformation/getResource:getResource", args, &rv, opts...)
if err != nil {
return nil, err
}
return &rv, nil
}
// A collection of arguments for invoking getResource.
type LookupResourceArgs struct {
// Amazon Resource Name (ARN) of the resource, an S3 path.
Arn string `pulumi:"arn"`
}
// A collection of values returned by getResource.
type LookupResourceResult struct {
Arn string `pulumi:"arn"`
// The provider-assigned unique ID for this managed resource.
Id string `pulumi:"id"`
// The date and time the resource was last modified in [RFC 3339 format](https://tools.ietf.org/html/rfc3339#section-5.8).
LastModified string `pulumi:"lastModified"`
// Role that the resource was registered with.
RoleArn string `pulumi:"roleArn"`
}