ResourceShareArgs

data class ResourceShareArgs(val allowExternalPrincipals: Output<Boolean>? = null, val name: Output<String>? = null, val permissionArns: Output<List<String>>? = null, val tags: Output<Map<String, String>>? = null) : ConvertibleToJava<ResourceShareArgs>

Manages a Resource Access Manager (RAM) Resource Share. To associate principals with the share, see the aws.ram.PrincipalAssociation resource. To associate resources with the share, see the aws.ram.ResourceAssociation resource.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.ram.ResourceShare("example", {
name: "example",
allowExternalPrincipals: true,
tags: {
Environment: "Production",
},
});
import pulumi
import pulumi_aws as aws
example = aws.ram.ResourceShare("example",
name="example",
allow_external_principals=True,
tags={
"Environment": "Production",
})
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.Ram.ResourceShare("example", new()
{
Name = "example",
AllowExternalPrincipals = true,
Tags =
{
{ "Environment", "Production" },
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ram"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ram.NewResourceShare(ctx, "example", &ram.ResourceShareArgs{
Name: pulumi.String("example"),
AllowExternalPrincipals: pulumi.Bool(true),
Tags: pulumi.StringMap{
"Environment": pulumi.String("Production"),
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ram.ResourceShare;
import com.pulumi.aws.ram.ResourceShareArgs;
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) {
var example = new ResourceShare("example", ResourceShareArgs.builder()
.name("example")
.allowExternalPrincipals(true)
.tags(Map.of("Environment", "Production"))
.build());
}
}
resources:
example:
type: aws:ram:ResourceShare
properties:
name: example
allowExternalPrincipals: true
tags:
Environment: Production

Import

Using pulumi import, import resource shares using the arn of the resource share. For example:

$ pulumi import aws:ram/resourceShare:ResourceShare example arn:aws:ram:eu-west-1:123456789012:resource-share/73da1ab9-b94a-4ba3-8eb4-45917f7f4b12

Constructors

Link copied to clipboard
constructor(allowExternalPrincipals: Output<Boolean>? = null, name: Output<String>? = null, permissionArns: Output<List<String>>? = null, tags: Output<Map<String, String>>? = null)

Properties

Link copied to clipboard
val allowExternalPrincipals: Output<Boolean>? = null

Indicates whether principals outside your organization can be associated with a resource share.

Link copied to clipboard
val name: Output<String>? = null

The name of the resource share.

Link copied to clipboard
val permissionArns: Output<List<String>>? = null

Specifies the Amazon Resource Names (ARNs) of the RAM permission to associate with the resource share. If you do not specify an ARN for the permission, RAM automatically attaches the default version of the permission for each resource type. You can associate only one permission with each resource type included in the resource share.

Link copied to clipboard
val tags: Output<Map<String, String>>? = null

A map of tags to assign to the resource share. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Functions

Link copied to clipboard
open override fun toJava(): ResourceShareArgs