Try AWS Native preview for resources not in the classic version.
AWS Classic v6.42.0 published on Wednesday, Jun 26, 2024 by Pulumi
aws.networkfirewall.getResourcePolicy
Explore with Pulumi AI
Try AWS Native preview for resources not in the classic version.
AWS Classic v6.42.0 published on Wednesday, Jun 26, 2024 by Pulumi
Retrieve information about a Network Firewall resource policy.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = aws.networkfirewall.getResourcePolicy({
resourceArn: resourcePolicyArn,
});
import pulumi
import pulumi_aws as aws
example = aws.networkfirewall.get_resource_policy(resource_arn=resource_policy_arn)
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkfirewall"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := networkfirewall.LookupResourcePolicy(ctx, &networkfirewall.LookupResourcePolicyArgs{
ResourceArn: resourcePolicyArn,
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = Aws.NetworkFirewall.GetResourcePolicy.Invoke(new()
{
ResourceArn = resourcePolicyArn,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.networkfirewall.NetworkfirewallFunctions;
import com.pulumi.aws.networkfirewall.inputs.GetResourcePolicyArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var example = NetworkfirewallFunctions.getResourcePolicy(GetResourcePolicyArgs.builder()
.resourceArn(resourcePolicyArn)
.build());
}
}
variables:
example:
fn::invoke:
Function: aws:networkfirewall:getResourcePolicy
Arguments:
resourceArn: ${resourcePolicyArn}
Using getResourcePolicy
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getResourcePolicy(args: GetResourcePolicyArgs, opts?: InvokeOptions): Promise<GetResourcePolicyResult>
function getResourcePolicyOutput(args: GetResourcePolicyOutputArgs, opts?: InvokeOptions): Output<GetResourcePolicyResult>
def get_resource_policy(resource_arn: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetResourcePolicyResult
def get_resource_policy_output(resource_arn: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetResourcePolicyResult]
func LookupResourcePolicy(ctx *Context, args *LookupResourcePolicyArgs, opts ...InvokeOption) (*LookupResourcePolicyResult, error)
func LookupResourcePolicyOutput(ctx *Context, args *LookupResourcePolicyOutputArgs, opts ...InvokeOption) LookupResourcePolicyResultOutput
> Note: This function is named LookupResourcePolicy
in the Go SDK.
public static class GetResourcePolicy
{
public static Task<GetResourcePolicyResult> InvokeAsync(GetResourcePolicyArgs args, InvokeOptions? opts = null)
public static Output<GetResourcePolicyResult> Invoke(GetResourcePolicyInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetResourcePolicyResult> getResourcePolicy(GetResourcePolicyArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: aws:networkfirewall/getResourcePolicy:getResourcePolicy
arguments:
# arguments dictionary
The following arguments are supported:
- Resource
Arn string - The Amazon Resource Name (ARN) that identifies the resource policy.
- Resource
Arn string - The Amazon Resource Name (ARN) that identifies the resource policy.
- resource
Arn String - The Amazon Resource Name (ARN) that identifies the resource policy.
- resource
Arn string - The Amazon Resource Name (ARN) that identifies the resource policy.
- resource_
arn str - The Amazon Resource Name (ARN) that identifies the resource policy.
- resource
Arn String - The Amazon Resource Name (ARN) that identifies the resource policy.
getResourcePolicy Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Policy string
- The [policy][1] for the resource.
- Resource
Arn string
- Id string
- The provider-assigned unique ID for this managed resource.
- Policy string
- The [policy][1] for the resource.
- Resource
Arn string
- id String
- The provider-assigned unique ID for this managed resource.
- policy String
- The [policy][1] for the resource.
- resource
Arn String
- id string
- The provider-assigned unique ID for this managed resource.
- policy string
- The [policy][1] for the resource.
- resource
Arn string
- id str
- The provider-assigned unique ID for this managed resource.
- policy str
- The [policy][1] for the resource.
- resource_
arn str
- id String
- The provider-assigned unique ID for this managed resource.
- policy String
- The [policy][1] for the resource.
- resource
Arn String
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.
Try AWS Native preview for resources not in the classic version.
AWS Classic v6.42.0 published on Wednesday, Jun 26, 2024 by Pulumi