sagemaker

package
v2.13.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 22, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Endpoint

type Endpoint struct {
	pulumi.CustomResourceState

	// The Amazon Resource Name (ARN) assigned by AWS to this endpoint.
	Arn pulumi.StringOutput `pulumi:"arn"`
	// The name of the endpoint configuration to use.
	EndpointConfigName pulumi.StringOutput `pulumi:"endpointConfigName"`
	// The name of the endpoint. If omitted, this provider will assign a random, unique name.
	Name pulumi.StringOutput `pulumi:"name"`
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapOutput `pulumi:"tags"`
}

Provides a SageMaker Endpoint resource.

## Example Usage

Basic usage:

```go package main

import (

"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/sagemaker"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := sagemaker.NewEndpoint(ctx, "endpoint", &sagemaker.EndpointArgs{
			EndpointConfigName: pulumi.String(aws_sagemaker_endpoint_configuration.Ec.Name),
			Tags: pulumi.StringMap{
				"Name": pulumi.String("foo"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

func GetEndpoint

func GetEndpoint(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *EndpointState, opts ...pulumi.ResourceOption) (*Endpoint, error)

GetEndpoint gets an existing Endpoint 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 NewEndpoint

func NewEndpoint(ctx *pulumi.Context,
	name string, args *EndpointArgs, opts ...pulumi.ResourceOption) (*Endpoint, error)

NewEndpoint registers a new resource with the given unique name, arguments, and options.

type EndpointArgs

type EndpointArgs struct {
	// The name of the endpoint configuration to use.
	EndpointConfigName pulumi.StringInput
	// The name of the endpoint. If omitted, this provider will assign a random, unique name.
	Name pulumi.StringPtrInput
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapInput
}

The set of arguments for constructing a Endpoint resource.

func (EndpointArgs) ElementType

func (EndpointArgs) ElementType() reflect.Type

type EndpointConfiguration

type EndpointConfiguration struct {
	pulumi.CustomResourceState

	// The Amazon Resource Name (ARN) assigned by AWS to this endpoint configuration.
	Arn pulumi.StringOutput `pulumi:"arn"`
	// Amazon Resource Name (ARN) of a AWS Key Management Service key that Amazon SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint.
	KmsKeyArn pulumi.StringPtrOutput `pulumi:"kmsKeyArn"`
	// The name of the endpoint configuration. If omitted, this provider will assign a random, unique name.
	Name pulumi.StringOutput `pulumi:"name"`
	// Fields are documented below.
	ProductionVariants EndpointConfigurationProductionVariantArrayOutput `pulumi:"productionVariants"`
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapOutput `pulumi:"tags"`
}

Provides a SageMaker endpoint configuration resource.

## Example Usage

Basic usage:

```go package main

import (

"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/sagemaker"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := sagemaker.NewEndpointConfiguration(ctx, "ec", &sagemaker.EndpointConfigurationArgs{
			ProductionVariants: sagemaker.EndpointConfigurationProductionVariantArray{
				&sagemaker.EndpointConfigurationProductionVariantArgs{
					InitialInstanceCount: pulumi.Int(1),
					InstanceType:         pulumi.String("ml.t2.medium"),
					ModelName:            pulumi.String(aws_sagemaker_model.M.Name),
					VariantName:          pulumi.String("variant-1"),
				},
			},
			Tags: pulumi.StringMap{
				"Name": pulumi.String("foo"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

func GetEndpointConfiguration

func GetEndpointConfiguration(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *EndpointConfigurationState, opts ...pulumi.ResourceOption) (*EndpointConfiguration, error)

GetEndpointConfiguration gets an existing EndpointConfiguration 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 NewEndpointConfiguration

func NewEndpointConfiguration(ctx *pulumi.Context,
	name string, args *EndpointConfigurationArgs, opts ...pulumi.ResourceOption) (*EndpointConfiguration, error)

NewEndpointConfiguration registers a new resource with the given unique name, arguments, and options.

type EndpointConfigurationArgs

type EndpointConfigurationArgs struct {
	// Amazon Resource Name (ARN) of a AWS Key Management Service key that Amazon SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint.
	KmsKeyArn pulumi.StringPtrInput
	// The name of the endpoint configuration. If omitted, this provider will assign a random, unique name.
	Name pulumi.StringPtrInput
	// Fields are documented below.
	ProductionVariants EndpointConfigurationProductionVariantArrayInput
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapInput
}

The set of arguments for constructing a EndpointConfiguration resource.

func (EndpointConfigurationArgs) ElementType

func (EndpointConfigurationArgs) ElementType() reflect.Type

type EndpointConfigurationProductionVariant

type EndpointConfigurationProductionVariant struct {
	// The size of the Elastic Inference (EI) instance to use for the production variant.
	AcceleratorType *string `pulumi:"acceleratorType"`
	// Initial number of instances used for auto-scaling.
	InitialInstanceCount int `pulumi:"initialInstanceCount"`
	// Determines initial traffic distribution among all of the models that you specify in the endpoint configuration. If unspecified, it defaults to 1.0.
	InitialVariantWeight *float64 `pulumi:"initialVariantWeight"`
	// The type of instance to start.
	InstanceType string `pulumi:"instanceType"`
	// The name of the model to use.
	ModelName string `pulumi:"modelName"`
	// The name of the variant. If omitted, this provider will assign a random, unique name.
	VariantName *string `pulumi:"variantName"`
}

type EndpointConfigurationProductionVariantArgs

type EndpointConfigurationProductionVariantArgs struct {
	// The size of the Elastic Inference (EI) instance to use for the production variant.
	AcceleratorType pulumi.StringPtrInput `pulumi:"acceleratorType"`
	// Initial number of instances used for auto-scaling.
	InitialInstanceCount pulumi.IntInput `pulumi:"initialInstanceCount"`
	// Determines initial traffic distribution among all of the models that you specify in the endpoint configuration. If unspecified, it defaults to 1.0.
	InitialVariantWeight pulumi.Float64PtrInput `pulumi:"initialVariantWeight"`
	// The type of instance to start.
	InstanceType pulumi.StringInput `pulumi:"instanceType"`
	// The name of the model to use.
	ModelName pulumi.StringInput `pulumi:"modelName"`
	// The name of the variant. If omitted, this provider will assign a random, unique name.
	VariantName pulumi.StringPtrInput `pulumi:"variantName"`
}

func (EndpointConfigurationProductionVariantArgs) ElementType

func (EndpointConfigurationProductionVariantArgs) ToEndpointConfigurationProductionVariantOutput

func (i EndpointConfigurationProductionVariantArgs) ToEndpointConfigurationProductionVariantOutput() EndpointConfigurationProductionVariantOutput

func (EndpointConfigurationProductionVariantArgs) ToEndpointConfigurationProductionVariantOutputWithContext

func (i EndpointConfigurationProductionVariantArgs) ToEndpointConfigurationProductionVariantOutputWithContext(ctx context.Context) EndpointConfigurationProductionVariantOutput

type EndpointConfigurationProductionVariantArray

type EndpointConfigurationProductionVariantArray []EndpointConfigurationProductionVariantInput

func (EndpointConfigurationProductionVariantArray) ElementType

func (EndpointConfigurationProductionVariantArray) ToEndpointConfigurationProductionVariantArrayOutput

func (i EndpointConfigurationProductionVariantArray) ToEndpointConfigurationProductionVariantArrayOutput() EndpointConfigurationProductionVariantArrayOutput

func (EndpointConfigurationProductionVariantArray) ToEndpointConfigurationProductionVariantArrayOutputWithContext

func (i EndpointConfigurationProductionVariantArray) ToEndpointConfigurationProductionVariantArrayOutputWithContext(ctx context.Context) EndpointConfigurationProductionVariantArrayOutput

type EndpointConfigurationProductionVariantArrayInput

type EndpointConfigurationProductionVariantArrayInput interface {
	pulumi.Input

	ToEndpointConfigurationProductionVariantArrayOutput() EndpointConfigurationProductionVariantArrayOutput
	ToEndpointConfigurationProductionVariantArrayOutputWithContext(context.Context) EndpointConfigurationProductionVariantArrayOutput
}

EndpointConfigurationProductionVariantArrayInput is an input type that accepts EndpointConfigurationProductionVariantArray and EndpointConfigurationProductionVariantArrayOutput values. You can construct a concrete instance of `EndpointConfigurationProductionVariantArrayInput` via:

EndpointConfigurationProductionVariantArray{ EndpointConfigurationProductionVariantArgs{...} }

type EndpointConfigurationProductionVariantArrayOutput

type EndpointConfigurationProductionVariantArrayOutput struct{ *pulumi.OutputState }

func (EndpointConfigurationProductionVariantArrayOutput) ElementType

func (EndpointConfigurationProductionVariantArrayOutput) Index

func (EndpointConfigurationProductionVariantArrayOutput) ToEndpointConfigurationProductionVariantArrayOutput

func (o EndpointConfigurationProductionVariantArrayOutput) ToEndpointConfigurationProductionVariantArrayOutput() EndpointConfigurationProductionVariantArrayOutput

func (EndpointConfigurationProductionVariantArrayOutput) ToEndpointConfigurationProductionVariantArrayOutputWithContext

func (o EndpointConfigurationProductionVariantArrayOutput) ToEndpointConfigurationProductionVariantArrayOutputWithContext(ctx context.Context) EndpointConfigurationProductionVariantArrayOutput

type EndpointConfigurationProductionVariantInput

type EndpointConfigurationProductionVariantInput interface {
	pulumi.Input

	ToEndpointConfigurationProductionVariantOutput() EndpointConfigurationProductionVariantOutput
	ToEndpointConfigurationProductionVariantOutputWithContext(context.Context) EndpointConfigurationProductionVariantOutput
}

EndpointConfigurationProductionVariantInput is an input type that accepts EndpointConfigurationProductionVariantArgs and EndpointConfigurationProductionVariantOutput values. You can construct a concrete instance of `EndpointConfigurationProductionVariantInput` via:

EndpointConfigurationProductionVariantArgs{...}

type EndpointConfigurationProductionVariantOutput

type EndpointConfigurationProductionVariantOutput struct{ *pulumi.OutputState }

func (EndpointConfigurationProductionVariantOutput) AcceleratorType

The size of the Elastic Inference (EI) instance to use for the production variant.

func (EndpointConfigurationProductionVariantOutput) ElementType

func (EndpointConfigurationProductionVariantOutput) InitialInstanceCount

Initial number of instances used for auto-scaling.

func (EndpointConfigurationProductionVariantOutput) InitialVariantWeight

Determines initial traffic distribution among all of the models that you specify in the endpoint configuration. If unspecified, it defaults to 1.0.

func (EndpointConfigurationProductionVariantOutput) InstanceType

The type of instance to start.

func (EndpointConfigurationProductionVariantOutput) ModelName

The name of the model to use.

func (EndpointConfigurationProductionVariantOutput) ToEndpointConfigurationProductionVariantOutput

func (o EndpointConfigurationProductionVariantOutput) ToEndpointConfigurationProductionVariantOutput() EndpointConfigurationProductionVariantOutput

func (EndpointConfigurationProductionVariantOutput) ToEndpointConfigurationProductionVariantOutputWithContext

func (o EndpointConfigurationProductionVariantOutput) ToEndpointConfigurationProductionVariantOutputWithContext(ctx context.Context) EndpointConfigurationProductionVariantOutput

func (EndpointConfigurationProductionVariantOutput) VariantName

The name of the variant. If omitted, this provider will assign a random, unique name.

type EndpointConfigurationState

type EndpointConfigurationState struct {
	// The Amazon Resource Name (ARN) assigned by AWS to this endpoint configuration.
	Arn pulumi.StringPtrInput
	// Amazon Resource Name (ARN) of a AWS Key Management Service key that Amazon SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint.
	KmsKeyArn pulumi.StringPtrInput
	// The name of the endpoint configuration. If omitted, this provider will assign a random, unique name.
	Name pulumi.StringPtrInput
	// Fields are documented below.
	ProductionVariants EndpointConfigurationProductionVariantArrayInput
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapInput
}

func (EndpointConfigurationState) ElementType

func (EndpointConfigurationState) ElementType() reflect.Type

type EndpointState

type EndpointState struct {
	// The Amazon Resource Name (ARN) assigned by AWS to this endpoint.
	Arn pulumi.StringPtrInput
	// The name of the endpoint configuration to use.
	EndpointConfigName pulumi.StringPtrInput
	// The name of the endpoint. If omitted, this provider will assign a random, unique name.
	Name pulumi.StringPtrInput
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapInput
}

func (EndpointState) ElementType

func (EndpointState) ElementType() reflect.Type

type Model

type Model struct {
	pulumi.CustomResourceState

	// The Amazon Resource Name (ARN) assigned by AWS to this model.
	Arn pulumi.StringOutput `pulumi:"arn"`
	// Specifies containers in the inference pipeline. If not specified, the `primaryContainer` argument is required. Fields are documented below.
	Containers ModelContainerArrayOutput `pulumi:"containers"`
	// Isolates the model container. No inbound or outbound network calls can be made to or from the model container.
	EnableNetworkIsolation pulumi.BoolPtrOutput `pulumi:"enableNetworkIsolation"`
	// A role that SageMaker can assume to access model artifacts and docker images for deployment.
	ExecutionRoleArn pulumi.StringOutput `pulumi:"executionRoleArn"`
	// The name of the model (must be unique). If omitted, this provider will assign a random, unique name.
	Name pulumi.StringOutput `pulumi:"name"`
	// The primary docker image containing inference code that is used when the model is deployed for predictions.  If not specified, the `container` argument is required. Fields are documented below.
	PrimaryContainer ModelPrimaryContainerPtrOutput `pulumi:"primaryContainer"`
	// A map of tags to assign to the resource.
	Tags pulumi.StringMapOutput `pulumi:"tags"`
	// Specifies the VPC that you want your model to connect to. VpcConfig is used in hosting services and in batch transform.
	VpcConfig ModelVpcConfigPtrOutput `pulumi:"vpcConfig"`
}

Provides a SageMaker model resource.

## Example Usage

Basic usage:

```go package main

import (

"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/iam"
"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/sagemaker"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := sagemaker.NewModel(ctx, "model", &sagemaker.ModelArgs{
			ExecutionRoleArn: pulumi.String(aws_iam_role.Foo.Arn),
			PrimaryContainer: &sagemaker.ModelPrimaryContainerArgs{
				Image: pulumi.String("174872318107.dkr.ecr.us-west-2.amazonaws.com/kmeans:1"),
			},
		})
		if err != nil {
			return err
		}
		assumeRole, err := iam.GetPolicyDocument(ctx, &iam.GetPolicyDocumentArgs{
			Statements: []iam.GetPolicyDocumentStatement{
				iam.GetPolicyDocumentStatement{
					Actions: []string{
						"sts:AssumeRole",
					},
					Principals: []iam.GetPolicyDocumentStatementPrincipal{
						iam.GetPolicyDocumentStatementPrincipal{
							Identifiers: []string{
								"sagemaker.amazonaws.com",
							},
							Type: "Service",
						},
					},
				},
			},
		}, nil)
		if err != nil {
			return err
		}
		_, err = iam.NewRole(ctx, "role", &iam.RoleArgs{
			AssumeRolePolicy: pulumi.String(assumeRole.Json),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

func GetModel

func GetModel(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *ModelState, opts ...pulumi.ResourceOption) (*Model, error)

GetModel gets an existing Model 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 NewModel

func NewModel(ctx *pulumi.Context,
	name string, args *ModelArgs, opts ...pulumi.ResourceOption) (*Model, error)

NewModel registers a new resource with the given unique name, arguments, and options.

type ModelArgs

type ModelArgs struct {
	// Specifies containers in the inference pipeline. If not specified, the `primaryContainer` argument is required. Fields are documented below.
	Containers ModelContainerArrayInput
	// Isolates the model container. No inbound or outbound network calls can be made to or from the model container.
	EnableNetworkIsolation pulumi.BoolPtrInput
	// A role that SageMaker can assume to access model artifacts and docker images for deployment.
	ExecutionRoleArn pulumi.StringInput
	// The name of the model (must be unique). If omitted, this provider will assign a random, unique name.
	Name pulumi.StringPtrInput
	// The primary docker image containing inference code that is used when the model is deployed for predictions.  If not specified, the `container` argument is required. Fields are documented below.
	PrimaryContainer ModelPrimaryContainerPtrInput
	// A map of tags to assign to the resource.
	Tags pulumi.StringMapInput
	// Specifies the VPC that you want your model to connect to. VpcConfig is used in hosting services and in batch transform.
	VpcConfig ModelVpcConfigPtrInput
}

The set of arguments for constructing a Model resource.

func (ModelArgs) ElementType

func (ModelArgs) ElementType() reflect.Type

type ModelContainer

type ModelContainer struct {
	// The DNS host name for the container.
	ContainerHostname *string `pulumi:"containerHostname"`
	// Environment variables for the Docker container.
	// A list of key value pairs.
	Environment map[string]string `pulumi:"environment"`
	// The registry path where the inference code image is stored in Amazon ECR.
	Image string `pulumi:"image"`
	// The URL for the S3 location where model artifacts are stored.
	ModelDataUrl *string `pulumi:"modelDataUrl"`
}

type ModelContainerArgs

type ModelContainerArgs struct {
	// The DNS host name for the container.
	ContainerHostname pulumi.StringPtrInput `pulumi:"containerHostname"`
	// Environment variables for the Docker container.
	// A list of key value pairs.
	Environment pulumi.StringMapInput `pulumi:"environment"`
	// The registry path where the inference code image is stored in Amazon ECR.
	Image pulumi.StringInput `pulumi:"image"`
	// The URL for the S3 location where model artifacts are stored.
	ModelDataUrl pulumi.StringPtrInput `pulumi:"modelDataUrl"`
}

func (ModelContainerArgs) ElementType

func (ModelContainerArgs) ElementType() reflect.Type

func (ModelContainerArgs) ToModelContainerOutput

func (i ModelContainerArgs) ToModelContainerOutput() ModelContainerOutput

func (ModelContainerArgs) ToModelContainerOutputWithContext

func (i ModelContainerArgs) ToModelContainerOutputWithContext(ctx context.Context) ModelContainerOutput

type ModelContainerArray

type ModelContainerArray []ModelContainerInput

func (ModelContainerArray) ElementType

func (ModelContainerArray) ElementType() reflect.Type

func (ModelContainerArray) ToModelContainerArrayOutput

func (i ModelContainerArray) ToModelContainerArrayOutput() ModelContainerArrayOutput

func (ModelContainerArray) ToModelContainerArrayOutputWithContext

func (i ModelContainerArray) ToModelContainerArrayOutputWithContext(ctx context.Context) ModelContainerArrayOutput

type ModelContainerArrayInput

type ModelContainerArrayInput interface {
	pulumi.Input

	ToModelContainerArrayOutput() ModelContainerArrayOutput
	ToModelContainerArrayOutputWithContext(context.Context) ModelContainerArrayOutput
}

ModelContainerArrayInput is an input type that accepts ModelContainerArray and ModelContainerArrayOutput values. You can construct a concrete instance of `ModelContainerArrayInput` via:

ModelContainerArray{ ModelContainerArgs{...} }

type ModelContainerArrayOutput

type ModelContainerArrayOutput struct{ *pulumi.OutputState }

func (ModelContainerArrayOutput) ElementType

func (ModelContainerArrayOutput) ElementType() reflect.Type

func (ModelContainerArrayOutput) Index

func (ModelContainerArrayOutput) ToModelContainerArrayOutput

func (o ModelContainerArrayOutput) ToModelContainerArrayOutput() ModelContainerArrayOutput

func (ModelContainerArrayOutput) ToModelContainerArrayOutputWithContext

func (o ModelContainerArrayOutput) ToModelContainerArrayOutputWithContext(ctx context.Context) ModelContainerArrayOutput

type ModelContainerInput

type ModelContainerInput interface {
	pulumi.Input

	ToModelContainerOutput() ModelContainerOutput
	ToModelContainerOutputWithContext(context.Context) ModelContainerOutput
}

ModelContainerInput is an input type that accepts ModelContainerArgs and ModelContainerOutput values. You can construct a concrete instance of `ModelContainerInput` via:

ModelContainerArgs{...}

type ModelContainerOutput

type ModelContainerOutput struct{ *pulumi.OutputState }

func (ModelContainerOutput) ContainerHostname

func (o ModelContainerOutput) ContainerHostname() pulumi.StringPtrOutput

The DNS host name for the container.

func (ModelContainerOutput) ElementType

func (ModelContainerOutput) ElementType() reflect.Type

func (ModelContainerOutput) Environment

Environment variables for the Docker container. A list of key value pairs.

func (ModelContainerOutput) Image

The registry path where the inference code image is stored in Amazon ECR.

func (ModelContainerOutput) ModelDataUrl

func (o ModelContainerOutput) ModelDataUrl() pulumi.StringPtrOutput

The URL for the S3 location where model artifacts are stored.

func (ModelContainerOutput) ToModelContainerOutput

func (o ModelContainerOutput) ToModelContainerOutput() ModelContainerOutput

func (ModelContainerOutput) ToModelContainerOutputWithContext

func (o ModelContainerOutput) ToModelContainerOutputWithContext(ctx context.Context) ModelContainerOutput

type ModelPrimaryContainer

type ModelPrimaryContainer struct {
	// The DNS host name for the container.
	ContainerHostname *string `pulumi:"containerHostname"`
	// Environment variables for the Docker container.
	// A list of key value pairs.
	Environment map[string]string `pulumi:"environment"`
	// The registry path where the inference code image is stored in Amazon ECR.
	Image string `pulumi:"image"`
	// The URL for the S3 location where model artifacts are stored.
	ModelDataUrl *string `pulumi:"modelDataUrl"`
}

type ModelPrimaryContainerArgs

type ModelPrimaryContainerArgs struct {
	// The DNS host name for the container.
	ContainerHostname pulumi.StringPtrInput `pulumi:"containerHostname"`
	// Environment variables for the Docker container.
	// A list of key value pairs.
	Environment pulumi.StringMapInput `pulumi:"environment"`
	// The registry path where the inference code image is stored in Amazon ECR.
	Image pulumi.StringInput `pulumi:"image"`
	// The URL for the S3 location where model artifacts are stored.
	ModelDataUrl pulumi.StringPtrInput `pulumi:"modelDataUrl"`
}

func (ModelPrimaryContainerArgs) ElementType

func (ModelPrimaryContainerArgs) ElementType() reflect.Type

func (ModelPrimaryContainerArgs) ToModelPrimaryContainerOutput

func (i ModelPrimaryContainerArgs) ToModelPrimaryContainerOutput() ModelPrimaryContainerOutput

func (ModelPrimaryContainerArgs) ToModelPrimaryContainerOutputWithContext

func (i ModelPrimaryContainerArgs) ToModelPrimaryContainerOutputWithContext(ctx context.Context) ModelPrimaryContainerOutput

func (ModelPrimaryContainerArgs) ToModelPrimaryContainerPtrOutput

func (i ModelPrimaryContainerArgs) ToModelPrimaryContainerPtrOutput() ModelPrimaryContainerPtrOutput

func (ModelPrimaryContainerArgs) ToModelPrimaryContainerPtrOutputWithContext

func (i ModelPrimaryContainerArgs) ToModelPrimaryContainerPtrOutputWithContext(ctx context.Context) ModelPrimaryContainerPtrOutput

type ModelPrimaryContainerInput

type ModelPrimaryContainerInput interface {
	pulumi.Input

	ToModelPrimaryContainerOutput() ModelPrimaryContainerOutput
	ToModelPrimaryContainerOutputWithContext(context.Context) ModelPrimaryContainerOutput
}

ModelPrimaryContainerInput is an input type that accepts ModelPrimaryContainerArgs and ModelPrimaryContainerOutput values. You can construct a concrete instance of `ModelPrimaryContainerInput` via:

ModelPrimaryContainerArgs{...}

type ModelPrimaryContainerOutput

type ModelPrimaryContainerOutput struct{ *pulumi.OutputState }

func (ModelPrimaryContainerOutput) ContainerHostname

func (o ModelPrimaryContainerOutput) ContainerHostname() pulumi.StringPtrOutput

The DNS host name for the container.

func (ModelPrimaryContainerOutput) ElementType

func (ModelPrimaryContainerOutput) Environment

Environment variables for the Docker container. A list of key value pairs.

func (ModelPrimaryContainerOutput) Image

The registry path where the inference code image is stored in Amazon ECR.

func (ModelPrimaryContainerOutput) ModelDataUrl

The URL for the S3 location where model artifacts are stored.

func (ModelPrimaryContainerOutput) ToModelPrimaryContainerOutput

func (o ModelPrimaryContainerOutput) ToModelPrimaryContainerOutput() ModelPrimaryContainerOutput

func (ModelPrimaryContainerOutput) ToModelPrimaryContainerOutputWithContext

func (o ModelPrimaryContainerOutput) ToModelPrimaryContainerOutputWithContext(ctx context.Context) ModelPrimaryContainerOutput

func (ModelPrimaryContainerOutput) ToModelPrimaryContainerPtrOutput

func (o ModelPrimaryContainerOutput) ToModelPrimaryContainerPtrOutput() ModelPrimaryContainerPtrOutput

func (ModelPrimaryContainerOutput) ToModelPrimaryContainerPtrOutputWithContext

func (o ModelPrimaryContainerOutput) ToModelPrimaryContainerPtrOutputWithContext(ctx context.Context) ModelPrimaryContainerPtrOutput

type ModelPrimaryContainerPtrInput

type ModelPrimaryContainerPtrInput interface {
	pulumi.Input

	ToModelPrimaryContainerPtrOutput() ModelPrimaryContainerPtrOutput
	ToModelPrimaryContainerPtrOutputWithContext(context.Context) ModelPrimaryContainerPtrOutput
}

ModelPrimaryContainerPtrInput is an input type that accepts ModelPrimaryContainerArgs, ModelPrimaryContainerPtr and ModelPrimaryContainerPtrOutput values. You can construct a concrete instance of `ModelPrimaryContainerPtrInput` via:

        ModelPrimaryContainerArgs{...}

or:

        nil

type ModelPrimaryContainerPtrOutput

type ModelPrimaryContainerPtrOutput struct{ *pulumi.OutputState }

func (ModelPrimaryContainerPtrOutput) ContainerHostname

The DNS host name for the container.

func (ModelPrimaryContainerPtrOutput) Elem

func (ModelPrimaryContainerPtrOutput) ElementType

func (ModelPrimaryContainerPtrOutput) Environment

Environment variables for the Docker container. A list of key value pairs.

func (ModelPrimaryContainerPtrOutput) Image

The registry path where the inference code image is stored in Amazon ECR.

func (ModelPrimaryContainerPtrOutput) ModelDataUrl

The URL for the S3 location where model artifacts are stored.

func (ModelPrimaryContainerPtrOutput) ToModelPrimaryContainerPtrOutput

func (o ModelPrimaryContainerPtrOutput) ToModelPrimaryContainerPtrOutput() ModelPrimaryContainerPtrOutput

func (ModelPrimaryContainerPtrOutput) ToModelPrimaryContainerPtrOutputWithContext

func (o ModelPrimaryContainerPtrOutput) ToModelPrimaryContainerPtrOutputWithContext(ctx context.Context) ModelPrimaryContainerPtrOutput

type ModelState

type ModelState struct {
	// The Amazon Resource Name (ARN) assigned by AWS to this model.
	Arn pulumi.StringPtrInput
	// Specifies containers in the inference pipeline. If not specified, the `primaryContainer` argument is required. Fields are documented below.
	Containers ModelContainerArrayInput
	// Isolates the model container. No inbound or outbound network calls can be made to or from the model container.
	EnableNetworkIsolation pulumi.BoolPtrInput
	// A role that SageMaker can assume to access model artifacts and docker images for deployment.
	ExecutionRoleArn pulumi.StringPtrInput
	// The name of the model (must be unique). If omitted, this provider will assign a random, unique name.
	Name pulumi.StringPtrInput
	// The primary docker image containing inference code that is used when the model is deployed for predictions.  If not specified, the `container` argument is required. Fields are documented below.
	PrimaryContainer ModelPrimaryContainerPtrInput
	// A map of tags to assign to the resource.
	Tags pulumi.StringMapInput
	// Specifies the VPC that you want your model to connect to. VpcConfig is used in hosting services and in batch transform.
	VpcConfig ModelVpcConfigPtrInput
}

func (ModelState) ElementType

func (ModelState) ElementType() reflect.Type

type ModelVpcConfig

type ModelVpcConfig struct {
	SecurityGroupIds []string `pulumi:"securityGroupIds"`
	Subnets          []string `pulumi:"subnets"`
}

type ModelVpcConfigArgs

type ModelVpcConfigArgs struct {
	SecurityGroupIds pulumi.StringArrayInput `pulumi:"securityGroupIds"`
	Subnets          pulumi.StringArrayInput `pulumi:"subnets"`
}

func (ModelVpcConfigArgs) ElementType

func (ModelVpcConfigArgs) ElementType() reflect.Type

func (ModelVpcConfigArgs) ToModelVpcConfigOutput

func (i ModelVpcConfigArgs) ToModelVpcConfigOutput() ModelVpcConfigOutput

func (ModelVpcConfigArgs) ToModelVpcConfigOutputWithContext

func (i ModelVpcConfigArgs) ToModelVpcConfigOutputWithContext(ctx context.Context) ModelVpcConfigOutput

func (ModelVpcConfigArgs) ToModelVpcConfigPtrOutput

func (i ModelVpcConfigArgs) ToModelVpcConfigPtrOutput() ModelVpcConfigPtrOutput

func (ModelVpcConfigArgs) ToModelVpcConfigPtrOutputWithContext

func (i ModelVpcConfigArgs) ToModelVpcConfigPtrOutputWithContext(ctx context.Context) ModelVpcConfigPtrOutput

type ModelVpcConfigInput

type ModelVpcConfigInput interface {
	pulumi.Input

	ToModelVpcConfigOutput() ModelVpcConfigOutput
	ToModelVpcConfigOutputWithContext(context.Context) ModelVpcConfigOutput
}

ModelVpcConfigInput is an input type that accepts ModelVpcConfigArgs and ModelVpcConfigOutput values. You can construct a concrete instance of `ModelVpcConfigInput` via:

ModelVpcConfigArgs{...}

type ModelVpcConfigOutput

type ModelVpcConfigOutput struct{ *pulumi.OutputState }

func (ModelVpcConfigOutput) ElementType

func (ModelVpcConfigOutput) ElementType() reflect.Type

func (ModelVpcConfigOutput) SecurityGroupIds

func (o ModelVpcConfigOutput) SecurityGroupIds() pulumi.StringArrayOutput

func (ModelVpcConfigOutput) Subnets

func (ModelVpcConfigOutput) ToModelVpcConfigOutput

func (o ModelVpcConfigOutput) ToModelVpcConfigOutput() ModelVpcConfigOutput

func (ModelVpcConfigOutput) ToModelVpcConfigOutputWithContext

func (o ModelVpcConfigOutput) ToModelVpcConfigOutputWithContext(ctx context.Context) ModelVpcConfigOutput

func (ModelVpcConfigOutput) ToModelVpcConfigPtrOutput

func (o ModelVpcConfigOutput) ToModelVpcConfigPtrOutput() ModelVpcConfigPtrOutput

func (ModelVpcConfigOutput) ToModelVpcConfigPtrOutputWithContext

func (o ModelVpcConfigOutput) ToModelVpcConfigPtrOutputWithContext(ctx context.Context) ModelVpcConfigPtrOutput

type ModelVpcConfigPtrInput

type ModelVpcConfigPtrInput interface {
	pulumi.Input

	ToModelVpcConfigPtrOutput() ModelVpcConfigPtrOutput
	ToModelVpcConfigPtrOutputWithContext(context.Context) ModelVpcConfigPtrOutput
}

ModelVpcConfigPtrInput is an input type that accepts ModelVpcConfigArgs, ModelVpcConfigPtr and ModelVpcConfigPtrOutput values. You can construct a concrete instance of `ModelVpcConfigPtrInput` via:

        ModelVpcConfigArgs{...}

or:

        nil

type ModelVpcConfigPtrOutput

type ModelVpcConfigPtrOutput struct{ *pulumi.OutputState }

func (ModelVpcConfigPtrOutput) Elem

func (ModelVpcConfigPtrOutput) ElementType

func (ModelVpcConfigPtrOutput) ElementType() reflect.Type

func (ModelVpcConfigPtrOutput) SecurityGroupIds

func (o ModelVpcConfigPtrOutput) SecurityGroupIds() pulumi.StringArrayOutput

func (ModelVpcConfigPtrOutput) Subnets

func (ModelVpcConfigPtrOutput) ToModelVpcConfigPtrOutput

func (o ModelVpcConfigPtrOutput) ToModelVpcConfigPtrOutput() ModelVpcConfigPtrOutput

func (ModelVpcConfigPtrOutput) ToModelVpcConfigPtrOutputWithContext

func (o ModelVpcConfigPtrOutput) ToModelVpcConfigPtrOutputWithContext(ctx context.Context) ModelVpcConfigPtrOutput

type NotebookInstance

type NotebookInstance struct {
	pulumi.CustomResourceState

	// The Amazon Resource Name (ARN) assigned by AWS to this notebook instance.
	Arn pulumi.StringOutput `pulumi:"arn"`
	// Set to `Disabled` to disable internet access to notebook. Requires `securityGroups` and `subnetId` to be set. Supported values: `Enabled` (Default) or `Disabled`. If set to `Disabled`, the notebook instance will be able to access resources only in your VPC, and will not be able to connect to Amazon SageMaker training and endpoint services unless your configure a NAT Gateway in your VPC.
	DirectInternetAccess pulumi.StringPtrOutput `pulumi:"directInternetAccess"`
	// The name of ML compute instance type.
	InstanceType pulumi.StringOutput `pulumi:"instanceType"`
	// The AWS Key Management Service (AWS KMS) key that Amazon SageMaker uses to encrypt the model artifacts at rest using Amazon S3 server-side encryption.
	KmsKeyId pulumi.StringPtrOutput `pulumi:"kmsKeyId"`
	// The name of a lifecycle configuration to associate with the notebook instance.
	LifecycleConfigName pulumi.StringPtrOutput `pulumi:"lifecycleConfigName"`
	// The name of the notebook instance (must be unique).
	Name pulumi.StringOutput `pulumi:"name"`
	// The ARN of the IAM role to be used by the notebook instance which allows SageMaker to call other services on your behalf.
	RoleArn pulumi.StringOutput `pulumi:"roleArn"`
	// The associated security groups.
	SecurityGroups pulumi.StringArrayOutput `pulumi:"securityGroups"`
	// The VPC subnet ID.
	SubnetId pulumi.StringPtrOutput `pulumi:"subnetId"`
	// A map of tags to assign to the resource.
	Tags pulumi.StringMapOutput `pulumi:"tags"`
}

Provides a Sagemaker Notebook Instance resource.

## Example Usage

Basic usage:

```go package main

import (

"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/sagemaker"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := sagemaker.NewNotebookInstance(ctx, "ni", &sagemaker.NotebookInstanceArgs{
			InstanceType: pulumi.String("ml.t2.medium"),
			RoleArn:      pulumi.String(aws_iam_role.Role.Arn),
			Tags: pulumi.StringMap{
				"Name": pulumi.String("foo"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

func GetNotebookInstance

func GetNotebookInstance(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *NotebookInstanceState, opts ...pulumi.ResourceOption) (*NotebookInstance, error)

GetNotebookInstance gets an existing NotebookInstance 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 NewNotebookInstance

func NewNotebookInstance(ctx *pulumi.Context,
	name string, args *NotebookInstanceArgs, opts ...pulumi.ResourceOption) (*NotebookInstance, error)

NewNotebookInstance registers a new resource with the given unique name, arguments, and options.

type NotebookInstanceArgs

type NotebookInstanceArgs struct {
	// Set to `Disabled` to disable internet access to notebook. Requires `securityGroups` and `subnetId` to be set. Supported values: `Enabled` (Default) or `Disabled`. If set to `Disabled`, the notebook instance will be able to access resources only in your VPC, and will not be able to connect to Amazon SageMaker training and endpoint services unless your configure a NAT Gateway in your VPC.
	DirectInternetAccess pulumi.StringPtrInput
	// The name of ML compute instance type.
	InstanceType pulumi.StringInput
	// The AWS Key Management Service (AWS KMS) key that Amazon SageMaker uses to encrypt the model artifacts at rest using Amazon S3 server-side encryption.
	KmsKeyId pulumi.StringPtrInput
	// The name of a lifecycle configuration to associate with the notebook instance.
	LifecycleConfigName pulumi.StringPtrInput
	// The name of the notebook instance (must be unique).
	Name pulumi.StringPtrInput
	// The ARN of the IAM role to be used by the notebook instance which allows SageMaker to call other services on your behalf.
	RoleArn pulumi.StringInput
	// The associated security groups.
	SecurityGroups pulumi.StringArrayInput
	// The VPC subnet ID.
	SubnetId pulumi.StringPtrInput
	// A map of tags to assign to the resource.
	Tags pulumi.StringMapInput
}

The set of arguments for constructing a NotebookInstance resource.

func (NotebookInstanceArgs) ElementType

func (NotebookInstanceArgs) ElementType() reflect.Type

type NotebookInstanceLifecycleConfiguration

type NotebookInstanceLifecycleConfiguration struct {
	pulumi.CustomResourceState

	// The Amazon Resource Name (ARN) assigned by AWS to this lifecycle configuration.
	Arn pulumi.StringOutput `pulumi:"arn"`
	// The name of the lifecycle configuration (must be unique). If omitted, this provider will assign a random, unique name.
	Name pulumi.StringOutput `pulumi:"name"`
	// A shell script (base64-encoded) that runs only once when the SageMaker Notebook Instance is created.
	OnCreate pulumi.StringPtrOutput `pulumi:"onCreate"`
	// A shell script (base64-encoded) that runs every time the SageMaker Notebook Instance is started including the time it's created.
	OnStart pulumi.StringPtrOutput `pulumi:"onStart"`
}

Provides a lifecycle configuration for SageMaker Notebook Instances.

func GetNotebookInstanceLifecycleConfiguration

func GetNotebookInstanceLifecycleConfiguration(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *NotebookInstanceLifecycleConfigurationState, opts ...pulumi.ResourceOption) (*NotebookInstanceLifecycleConfiguration, error)

GetNotebookInstanceLifecycleConfiguration gets an existing NotebookInstanceLifecycleConfiguration 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 NewNotebookInstanceLifecycleConfiguration

func NewNotebookInstanceLifecycleConfiguration(ctx *pulumi.Context,
	name string, args *NotebookInstanceLifecycleConfigurationArgs, opts ...pulumi.ResourceOption) (*NotebookInstanceLifecycleConfiguration, error)

NewNotebookInstanceLifecycleConfiguration registers a new resource with the given unique name, arguments, and options.

type NotebookInstanceLifecycleConfigurationArgs

type NotebookInstanceLifecycleConfigurationArgs struct {
	// The name of the lifecycle configuration (must be unique). If omitted, this provider will assign a random, unique name.
	Name pulumi.StringPtrInput
	// A shell script (base64-encoded) that runs only once when the SageMaker Notebook Instance is created.
	OnCreate pulumi.StringPtrInput
	// A shell script (base64-encoded) that runs every time the SageMaker Notebook Instance is started including the time it's created.
	OnStart pulumi.StringPtrInput
}

The set of arguments for constructing a NotebookInstanceLifecycleConfiguration resource.

func (NotebookInstanceLifecycleConfigurationArgs) ElementType

type NotebookInstanceLifecycleConfigurationState

type NotebookInstanceLifecycleConfigurationState struct {
	// The Amazon Resource Name (ARN) assigned by AWS to this lifecycle configuration.
	Arn pulumi.StringPtrInput
	// The name of the lifecycle configuration (must be unique). If omitted, this provider will assign a random, unique name.
	Name pulumi.StringPtrInput
	// A shell script (base64-encoded) that runs only once when the SageMaker Notebook Instance is created.
	OnCreate pulumi.StringPtrInput
	// A shell script (base64-encoded) that runs every time the SageMaker Notebook Instance is started including the time it's created.
	OnStart pulumi.StringPtrInput
}

func (NotebookInstanceLifecycleConfigurationState) ElementType

type NotebookInstanceState

type NotebookInstanceState struct {
	// The Amazon Resource Name (ARN) assigned by AWS to this notebook instance.
	Arn pulumi.StringPtrInput
	// Set to `Disabled` to disable internet access to notebook. Requires `securityGroups` and `subnetId` to be set. Supported values: `Enabled` (Default) or `Disabled`. If set to `Disabled`, the notebook instance will be able to access resources only in your VPC, and will not be able to connect to Amazon SageMaker training and endpoint services unless your configure a NAT Gateway in your VPC.
	DirectInternetAccess pulumi.StringPtrInput
	// The name of ML compute instance type.
	InstanceType pulumi.StringPtrInput
	// The AWS Key Management Service (AWS KMS) key that Amazon SageMaker uses to encrypt the model artifacts at rest using Amazon S3 server-side encryption.
	KmsKeyId pulumi.StringPtrInput
	// The name of a lifecycle configuration to associate with the notebook instance.
	LifecycleConfigName pulumi.StringPtrInput
	// The name of the notebook instance (must be unique).
	Name pulumi.StringPtrInput
	// The ARN of the IAM role to be used by the notebook instance which allows SageMaker to call other services on your behalf.
	RoleArn pulumi.StringPtrInput
	// The associated security groups.
	SecurityGroups pulumi.StringArrayInput
	// The VPC subnet ID.
	SubnetId pulumi.StringPtrInput
	// A map of tags to assign to the resource.
	Tags pulumi.StringMapInput
}

func (NotebookInstanceState) ElementType

func (NotebookInstanceState) ElementType() reflect.Type

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL