Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Container ¶
type Container struct { pulumi.CustomResourceState // The ARN of the container. Arn pulumi.StringOutput `pulumi:"arn"` // The DNS endpoint of the container. Endpoint pulumi.StringOutput `pulumi:"endpoint"` // The name of the container. Must contain alphanumeric characters or underscores. Name pulumi.StringOutput `pulumi:"name"` // A map of tags to assign to the resource. Tags pulumi.StringMapOutput `pulumi:"tags"` }
Provides a MediaStore Container.
## Example Usage
```go package main
import (
"github.com/pulumi/pulumi-aws/sdk/v3/go/aws/mediastore" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := mediastore.NewContainer(ctx, "example", nil) if err != nil { return err } return nil }) }
```
func GetContainer ¶
func GetContainer(ctx *pulumi.Context, name string, id pulumi.IDInput, state *ContainerState, opts ...pulumi.ResourceOption) (*Container, error)
GetContainer gets an existing Container resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewContainer ¶
func NewContainer(ctx *pulumi.Context, name string, args *ContainerArgs, opts ...pulumi.ResourceOption) (*Container, error)
NewContainer registers a new resource with the given unique name, arguments, and options.
type ContainerArgs ¶
type ContainerArgs struct { // The name of the container. Must contain alphanumeric characters or underscores. Name pulumi.StringPtrInput // A map of tags to assign to the resource. Tags pulumi.StringMapInput }
The set of arguments for constructing a Container resource.
func (ContainerArgs) ElementType ¶
func (ContainerArgs) ElementType() reflect.Type
type ContainerPolicy ¶
type ContainerPolicy struct { pulumi.CustomResourceState // The name of the container. ContainerName pulumi.StringOutput `pulumi:"containerName"` // The contents of the policy. Policy pulumi.StringOutput `pulumi:"policy"` }
Provides a MediaStore Container Policy.
## Example Usage
```go package main
import (
"fmt" "github.com/pulumi/pulumi-aws/sdk/v3/go/aws" "github.com/pulumi/pulumi-aws/sdk/v3/go/aws/mediastore" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { currentRegion, err := aws.GetRegion(ctx, nil, nil) if err != nil { return err } currentCallerIdentity, err := aws.GetCallerIdentity(ctx, nil, nil) if err != nil { return err } exampleContainer, err := mediastore.NewContainer(ctx, "exampleContainer", nil) if err != nil { return err } _, err = mediastore.NewContainerPolicy(ctx, "exampleContainerPolicy", &mediastore.ContainerPolicyArgs{ ContainerName: exampleContainer.Name, Policy: exampleContainer.Name.ApplyT(func(name string) (string, error) { return fmt.Sprintf("%v%v%v%v%v%v%v%v%v%v%v%v%v%v%v%v%v%v%v%v%v", "{\n", " \"Version\": \"2012-10-17\",\n", " \"Statement\": [{\n", " \"Sid\": \"MediaStoreFullAccess\",\n", " \"Action\": [ \"mediastore:*\" ],\n", " \"Principal\": {\"AWS\" : \"arn:aws:iam::", currentCallerIdentity.AccountId, ":root\"},\n", " \"Effect\": \"Allow\",\n", " \"Resource\": \"arn:aws:mediastore:", currentRegion.Name, ":", currentCallerIdentity.AccountId, ":container/", name, "/*\",\n", " \"Condition\": {\n", " \"Bool\": { \"aws:SecureTransport\": \"true\" }\n", " }\n", " }]\n", "}\n"), nil }).(pulumi.StringOutput), }) if err != nil { return err } return nil }) }
```
func GetContainerPolicy ¶
func GetContainerPolicy(ctx *pulumi.Context, name string, id pulumi.IDInput, state *ContainerPolicyState, opts ...pulumi.ResourceOption) (*ContainerPolicy, error)
GetContainerPolicy gets an existing ContainerPolicy resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewContainerPolicy ¶
func NewContainerPolicy(ctx *pulumi.Context, name string, args *ContainerPolicyArgs, opts ...pulumi.ResourceOption) (*ContainerPolicy, error)
NewContainerPolicy registers a new resource with the given unique name, arguments, and options.
type ContainerPolicyArgs ¶
type ContainerPolicyArgs struct { // The name of the container. ContainerName pulumi.StringInput // The contents of the policy. Policy pulumi.StringInput }
The set of arguments for constructing a ContainerPolicy resource.
func (ContainerPolicyArgs) ElementType ¶
func (ContainerPolicyArgs) ElementType() reflect.Type
type ContainerPolicyState ¶
type ContainerPolicyState struct { // The name of the container. ContainerName pulumi.StringPtrInput // The contents of the policy. Policy pulumi.StringPtrInput }
func (ContainerPolicyState) ElementType ¶
func (ContainerPolicyState) ElementType() reflect.Type
type ContainerState ¶
type ContainerState struct { // The ARN of the container. Arn pulumi.StringPtrInput // The DNS endpoint of the container. Endpoint pulumi.StringPtrInput // The name of the container. Must contain alphanumeric characters or underscores. Name pulumi.StringPtrInput // A map of tags to assign to the resource. Tags pulumi.StringMapInput }
func (ContainerState) ElementType ¶
func (ContainerState) ElementType() reflect.Type