notebooks

package
v4.11.0 Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Environment

type Environment struct {
	pulumi.CustomResourceState

	// Use a container image to start the notebook instance.
	// Structure is documented below.
	ContainerImage EnvironmentContainerImagePtrOutput `pulumi:"containerImage"`
	// Instance creation time
	CreateTime pulumi.StringOutput `pulumi:"createTime"`
	// A brief description of this environment.
	Description pulumi.StringPtrOutput `pulumi:"description"`
	// Display name of this environment for the UI.
	DisplayName pulumi.StringPtrOutput `pulumi:"displayName"`
	// A reference to the zone where the machine resides.
	Location pulumi.StringOutput `pulumi:"location"`
	// The name specified for the Environment instance.
	// Format: projects/{project_id}/locations/{location}/environments/{environmentId}
	Name pulumi.StringOutput `pulumi:"name"`
	// Path to a Bash script that automatically runs after a notebook instance fully boots up.
	// The path must be a URL or Cloud Storage path. Example: "gs://path-to-file/file-name"
	PostStartupScript pulumi.StringPtrOutput `pulumi:"postStartupScript"`
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project pulumi.StringOutput `pulumi:"project"`
	// Use a Compute Engine VM image to start the notebook instance.
	// Structure is documented below.
	VmImage EnvironmentVmImagePtrOutput `pulumi:"vmImage"`
}

A Cloud AI Platform Notebook environment.

To get more information about Environment, see:

* [API documentation](https://cloud.google.com/ai-platform/notebooks/docs/reference/rest) * How-to Guides

## Example Usage ### Notebook Environment Basic

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewEnvironment(ctx, "environment", &notebooks.EnvironmentArgs{
			ContainerImage: &notebooks.EnvironmentContainerImageArgs{
				Repository: pulumi.String("gcr.io/deeplearning-platform-release/base-cpu"),
			},
			Location: pulumi.String("us-west1-a"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## Import

Environment can be imported using any of these accepted formats

```sh

$ pulumi import gcp:notebooks/environment:Environment default projects/{{project}}/locations/{{location}}/environments/{{name}}

```

```sh

$ pulumi import gcp:notebooks/environment:Environment default {{project}}/{{location}}/{{name}}

```

```sh

$ pulumi import gcp:notebooks/environment:Environment default {{location}}/{{name}}

```

func GetEnvironment

func GetEnvironment(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *EnvironmentState, opts ...pulumi.ResourceOption) (*Environment, error)

GetEnvironment gets an existing Environment 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 NewEnvironment

func NewEnvironment(ctx *pulumi.Context,
	name string, args *EnvironmentArgs, opts ...pulumi.ResourceOption) (*Environment, error)

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

func (*Environment) ElementType added in v4.4.0

func (*Environment) ElementType() reflect.Type

func (*Environment) ToEnvironmentOutput added in v4.4.0

func (i *Environment) ToEnvironmentOutput() EnvironmentOutput

func (*Environment) ToEnvironmentOutputWithContext added in v4.4.0

func (i *Environment) ToEnvironmentOutputWithContext(ctx context.Context) EnvironmentOutput

type EnvironmentArgs

type EnvironmentArgs struct {
	// Use a container image to start the notebook instance.
	// Structure is documented below.
	ContainerImage EnvironmentContainerImagePtrInput
	// A brief description of this environment.
	Description pulumi.StringPtrInput
	// Display name of this environment for the UI.
	DisplayName pulumi.StringPtrInput
	// A reference to the zone where the machine resides.
	Location pulumi.StringInput
	// The name specified for the Environment instance.
	// Format: projects/{project_id}/locations/{location}/environments/{environmentId}
	Name pulumi.StringPtrInput
	// Path to a Bash script that automatically runs after a notebook instance fully boots up.
	// The path must be a URL or Cloud Storage path. Example: "gs://path-to-file/file-name"
	PostStartupScript pulumi.StringPtrInput
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project pulumi.StringPtrInput
	// Use a Compute Engine VM image to start the notebook instance.
	// Structure is documented below.
	VmImage EnvironmentVmImagePtrInput
}

The set of arguments for constructing a Environment resource.

func (EnvironmentArgs) ElementType

func (EnvironmentArgs) ElementType() reflect.Type

type EnvironmentContainerImage

type EnvironmentContainerImage struct {
	// The path to the container image repository.
	// For example: gcr.io/{project_id}/{imageName}
	Repository string `pulumi:"repository"`
	// The tag of the container image. If not specified, this defaults to the latest tag.
	Tag *string `pulumi:"tag"`
}

type EnvironmentContainerImageArgs

type EnvironmentContainerImageArgs struct {
	// The path to the container image repository.
	// For example: gcr.io/{project_id}/{imageName}
	Repository pulumi.StringInput `pulumi:"repository"`
	// The tag of the container image. If not specified, this defaults to the latest tag.
	Tag pulumi.StringPtrInput `pulumi:"tag"`
}

func (EnvironmentContainerImageArgs) ElementType

func (EnvironmentContainerImageArgs) ToEnvironmentContainerImageOutput

func (i EnvironmentContainerImageArgs) ToEnvironmentContainerImageOutput() EnvironmentContainerImageOutput

func (EnvironmentContainerImageArgs) ToEnvironmentContainerImageOutputWithContext

func (i EnvironmentContainerImageArgs) ToEnvironmentContainerImageOutputWithContext(ctx context.Context) EnvironmentContainerImageOutput

func (EnvironmentContainerImageArgs) ToEnvironmentContainerImagePtrOutput

func (i EnvironmentContainerImageArgs) ToEnvironmentContainerImagePtrOutput() EnvironmentContainerImagePtrOutput

func (EnvironmentContainerImageArgs) ToEnvironmentContainerImagePtrOutputWithContext

func (i EnvironmentContainerImageArgs) ToEnvironmentContainerImagePtrOutputWithContext(ctx context.Context) EnvironmentContainerImagePtrOutput

type EnvironmentContainerImageInput

type EnvironmentContainerImageInput interface {
	pulumi.Input

	ToEnvironmentContainerImageOutput() EnvironmentContainerImageOutput
	ToEnvironmentContainerImageOutputWithContext(context.Context) EnvironmentContainerImageOutput
}

EnvironmentContainerImageInput is an input type that accepts EnvironmentContainerImageArgs and EnvironmentContainerImageOutput values. You can construct a concrete instance of `EnvironmentContainerImageInput` via:

EnvironmentContainerImageArgs{...}

type EnvironmentContainerImageOutput

type EnvironmentContainerImageOutput struct{ *pulumi.OutputState }

func (EnvironmentContainerImageOutput) ElementType

func (EnvironmentContainerImageOutput) Repository

The path to the container image repository. For example: gcr.io/{project_id}/{imageName}

func (EnvironmentContainerImageOutput) Tag

The tag of the container image. If not specified, this defaults to the latest tag.

func (EnvironmentContainerImageOutput) ToEnvironmentContainerImageOutput

func (o EnvironmentContainerImageOutput) ToEnvironmentContainerImageOutput() EnvironmentContainerImageOutput

func (EnvironmentContainerImageOutput) ToEnvironmentContainerImageOutputWithContext

func (o EnvironmentContainerImageOutput) ToEnvironmentContainerImageOutputWithContext(ctx context.Context) EnvironmentContainerImageOutput

func (EnvironmentContainerImageOutput) ToEnvironmentContainerImagePtrOutput

func (o EnvironmentContainerImageOutput) ToEnvironmentContainerImagePtrOutput() EnvironmentContainerImagePtrOutput

func (EnvironmentContainerImageOutput) ToEnvironmentContainerImagePtrOutputWithContext

func (o EnvironmentContainerImageOutput) ToEnvironmentContainerImagePtrOutputWithContext(ctx context.Context) EnvironmentContainerImagePtrOutput

type EnvironmentContainerImagePtrInput

type EnvironmentContainerImagePtrInput interface {
	pulumi.Input

	ToEnvironmentContainerImagePtrOutput() EnvironmentContainerImagePtrOutput
	ToEnvironmentContainerImagePtrOutputWithContext(context.Context) EnvironmentContainerImagePtrOutput
}

EnvironmentContainerImagePtrInput is an input type that accepts EnvironmentContainerImageArgs, EnvironmentContainerImagePtr and EnvironmentContainerImagePtrOutput values. You can construct a concrete instance of `EnvironmentContainerImagePtrInput` via:

        EnvironmentContainerImageArgs{...}

or:

        nil

type EnvironmentContainerImagePtrOutput

type EnvironmentContainerImagePtrOutput struct{ *pulumi.OutputState }

func (EnvironmentContainerImagePtrOutput) Elem

func (EnvironmentContainerImagePtrOutput) ElementType

func (EnvironmentContainerImagePtrOutput) Repository

The path to the container image repository. For example: gcr.io/{project_id}/{imageName}

func (EnvironmentContainerImagePtrOutput) Tag

The tag of the container image. If not specified, this defaults to the latest tag.

func (EnvironmentContainerImagePtrOutput) ToEnvironmentContainerImagePtrOutput

func (o EnvironmentContainerImagePtrOutput) ToEnvironmentContainerImagePtrOutput() EnvironmentContainerImagePtrOutput

func (EnvironmentContainerImagePtrOutput) ToEnvironmentContainerImagePtrOutputWithContext

func (o EnvironmentContainerImagePtrOutput) ToEnvironmentContainerImagePtrOutputWithContext(ctx context.Context) EnvironmentContainerImagePtrOutput

type EnvironmentInput added in v4.4.0

type EnvironmentInput interface {
	pulumi.Input

	ToEnvironmentOutput() EnvironmentOutput
	ToEnvironmentOutputWithContext(ctx context.Context) EnvironmentOutput
}

type EnvironmentOutput added in v4.4.0

type EnvironmentOutput struct {
	*pulumi.OutputState
}

func (EnvironmentOutput) ElementType added in v4.4.0

func (EnvironmentOutput) ElementType() reflect.Type

func (EnvironmentOutput) ToEnvironmentOutput added in v4.4.0

func (o EnvironmentOutput) ToEnvironmentOutput() EnvironmentOutput

func (EnvironmentOutput) ToEnvironmentOutputWithContext added in v4.4.0

func (o EnvironmentOutput) ToEnvironmentOutputWithContext(ctx context.Context) EnvironmentOutput

type EnvironmentState

type EnvironmentState struct {
	// Use a container image to start the notebook instance.
	// Structure is documented below.
	ContainerImage EnvironmentContainerImagePtrInput
	// Instance creation time
	CreateTime pulumi.StringPtrInput
	// A brief description of this environment.
	Description pulumi.StringPtrInput
	// Display name of this environment for the UI.
	DisplayName pulumi.StringPtrInput
	// A reference to the zone where the machine resides.
	Location pulumi.StringPtrInput
	// The name specified for the Environment instance.
	// Format: projects/{project_id}/locations/{location}/environments/{environmentId}
	Name pulumi.StringPtrInput
	// Path to a Bash script that automatically runs after a notebook instance fully boots up.
	// The path must be a URL or Cloud Storage path. Example: "gs://path-to-file/file-name"
	PostStartupScript pulumi.StringPtrInput
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project pulumi.StringPtrInput
	// Use a Compute Engine VM image to start the notebook instance.
	// Structure is documented below.
	VmImage EnvironmentVmImagePtrInput
}

func (EnvironmentState) ElementType

func (EnvironmentState) ElementType() reflect.Type

type EnvironmentVmImage

type EnvironmentVmImage struct {
	// Use this VM image family to find the image; the newest image in this family will be used.
	ImageFamily *string `pulumi:"imageFamily"`
	// Use VM image name to find the image.
	ImageName *string `pulumi:"imageName"`
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project string `pulumi:"project"`
}

type EnvironmentVmImageArgs

type EnvironmentVmImageArgs struct {
	// Use this VM image family to find the image; the newest image in this family will be used.
	ImageFamily pulumi.StringPtrInput `pulumi:"imageFamily"`
	// Use VM image name to find the image.
	ImageName pulumi.StringPtrInput `pulumi:"imageName"`
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project pulumi.StringInput `pulumi:"project"`
}

func (EnvironmentVmImageArgs) ElementType

func (EnvironmentVmImageArgs) ElementType() reflect.Type

func (EnvironmentVmImageArgs) ToEnvironmentVmImageOutput

func (i EnvironmentVmImageArgs) ToEnvironmentVmImageOutput() EnvironmentVmImageOutput

func (EnvironmentVmImageArgs) ToEnvironmentVmImageOutputWithContext

func (i EnvironmentVmImageArgs) ToEnvironmentVmImageOutputWithContext(ctx context.Context) EnvironmentVmImageOutput

func (EnvironmentVmImageArgs) ToEnvironmentVmImagePtrOutput

func (i EnvironmentVmImageArgs) ToEnvironmentVmImagePtrOutput() EnvironmentVmImagePtrOutput

func (EnvironmentVmImageArgs) ToEnvironmentVmImagePtrOutputWithContext

func (i EnvironmentVmImageArgs) ToEnvironmentVmImagePtrOutputWithContext(ctx context.Context) EnvironmentVmImagePtrOutput

type EnvironmentVmImageInput

type EnvironmentVmImageInput interface {
	pulumi.Input

	ToEnvironmentVmImageOutput() EnvironmentVmImageOutput
	ToEnvironmentVmImageOutputWithContext(context.Context) EnvironmentVmImageOutput
}

EnvironmentVmImageInput is an input type that accepts EnvironmentVmImageArgs and EnvironmentVmImageOutput values. You can construct a concrete instance of `EnvironmentVmImageInput` via:

EnvironmentVmImageArgs{...}

type EnvironmentVmImageOutput

type EnvironmentVmImageOutput struct{ *pulumi.OutputState }

func (EnvironmentVmImageOutput) ElementType

func (EnvironmentVmImageOutput) ElementType() reflect.Type

func (EnvironmentVmImageOutput) ImageFamily

Use this VM image family to find the image; the newest image in this family will be used.

func (EnvironmentVmImageOutput) ImageName

Use VM image name to find the image.

func (EnvironmentVmImageOutput) Project

The name of the Google Cloud project that this VM image belongs to. Format: projects/{project_id}

func (EnvironmentVmImageOutput) ToEnvironmentVmImageOutput

func (o EnvironmentVmImageOutput) ToEnvironmentVmImageOutput() EnvironmentVmImageOutput

func (EnvironmentVmImageOutput) ToEnvironmentVmImageOutputWithContext

func (o EnvironmentVmImageOutput) ToEnvironmentVmImageOutputWithContext(ctx context.Context) EnvironmentVmImageOutput

func (EnvironmentVmImageOutput) ToEnvironmentVmImagePtrOutput

func (o EnvironmentVmImageOutput) ToEnvironmentVmImagePtrOutput() EnvironmentVmImagePtrOutput

func (EnvironmentVmImageOutput) ToEnvironmentVmImagePtrOutputWithContext

func (o EnvironmentVmImageOutput) ToEnvironmentVmImagePtrOutputWithContext(ctx context.Context) EnvironmentVmImagePtrOutput

type EnvironmentVmImagePtrInput

type EnvironmentVmImagePtrInput interface {
	pulumi.Input

	ToEnvironmentVmImagePtrOutput() EnvironmentVmImagePtrOutput
	ToEnvironmentVmImagePtrOutputWithContext(context.Context) EnvironmentVmImagePtrOutput
}

EnvironmentVmImagePtrInput is an input type that accepts EnvironmentVmImageArgs, EnvironmentVmImagePtr and EnvironmentVmImagePtrOutput values. You can construct a concrete instance of `EnvironmentVmImagePtrInput` via:

        EnvironmentVmImageArgs{...}

or:

        nil

type EnvironmentVmImagePtrOutput

type EnvironmentVmImagePtrOutput struct{ *pulumi.OutputState }

func (EnvironmentVmImagePtrOutput) Elem

func (EnvironmentVmImagePtrOutput) ElementType

func (EnvironmentVmImagePtrOutput) ImageFamily

Use this VM image family to find the image; the newest image in this family will be used.

func (EnvironmentVmImagePtrOutput) ImageName

Use VM image name to find the image.

func (EnvironmentVmImagePtrOutput) Project

The name of the Google Cloud project that this VM image belongs to. Format: projects/{project_id}

func (EnvironmentVmImagePtrOutput) ToEnvironmentVmImagePtrOutput

func (o EnvironmentVmImagePtrOutput) ToEnvironmentVmImagePtrOutput() EnvironmentVmImagePtrOutput

func (EnvironmentVmImagePtrOutput) ToEnvironmentVmImagePtrOutputWithContext

func (o EnvironmentVmImagePtrOutput) ToEnvironmentVmImagePtrOutputWithContext(ctx context.Context) EnvironmentVmImagePtrOutput

type Instance

type Instance struct {
	pulumi.CustomResourceState

	// The hardware accelerator used on this instance. If you use accelerators,
	// make sure that your configuration has enough vCPUs and memory to support the
	// machineType you have selected.
	// Structure is documented below.
	AcceleratorConfig InstanceAcceleratorConfigPtrOutput `pulumi:"acceleratorConfig"`
	// The size of the boot disk in GB attached to this instance,
	// up to a maximum of 64000 GB (64 TB). The minimum recommended value is 100 GB.
	// If not specified, this defaults to 100.
	BootDiskSizeGb pulumi.IntPtrOutput `pulumi:"bootDiskSizeGb"`
	// Possible disk types for notebook instances.
	// Possible values are `DISK_TYPE_UNSPECIFIED`, `PD_STANDARD`, `PD_SSD`, and `PD_BALANCED`.
	BootDiskType pulumi.StringPtrOutput `pulumi:"bootDiskType"`
	// Use a container image to start the notebook instance.
	// Structure is documented below.
	ContainerImage InstanceContainerImagePtrOutput `pulumi:"containerImage"`
	// Instance creation time
	CreateTime pulumi.StringOutput `pulumi:"createTime"`
	// Specify a custom Cloud Storage path where the GPU driver is stored.
	// If not specified, we'll automatically choose from official GPU drivers.
	CustomGpuDriverPath pulumi.StringPtrOutput `pulumi:"customGpuDriverPath"`
	// The size of the data disk in GB attached to this instance,
	// up to a maximum of 64000 GB (64 TB).
	// You can choose the size of the data disk based on how big your notebooks and data are.
	// If not specified, this defaults to 100.
	DataDiskSizeGb pulumi.IntPtrOutput `pulumi:"dataDiskSizeGb"`
	// Possible disk types for notebook instances.
	// Possible values are `DISK_TYPE_UNSPECIFIED`, `PD_STANDARD`, `PD_SSD`, and `PD_BALANCED`.
	DataDiskType pulumi.StringPtrOutput `pulumi:"dataDiskType"`
	// Disk encryption method used on the boot and data disks, defaults to GMEK.
	// Possible values are `DISK_ENCRYPTION_UNSPECIFIED`, `GMEK`, and `CMEK`.
	DiskEncryption pulumi.StringPtrOutput `pulumi:"diskEncryption"`
	// Whether the end user authorizes Google Cloud to install GPU driver
	// on this instance. If this field is empty or set to false, the GPU driver
	// won't be installed. Only applicable to instances with GPUs.
	InstallGpuDriver pulumi.BoolPtrOutput `pulumi:"installGpuDriver"`
	// The list of owners of this instance after creation.
	// Format: alias@example.com.
	// Currently supports one owner only.
	// If not specified, all of the service account users of
	// your VM instance's service account can use the instance.
	InstanceOwners pulumi.StringPtrOutput `pulumi:"instanceOwners"`
	// The KMS key used to encrypt the disks, only applicable if diskEncryption is CMEK.
	// Format: projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}
	KmsKey pulumi.StringPtrOutput `pulumi:"kmsKey"`
	// Labels to apply to this instance. These can be later modified by the setLabels method.
	// An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
	Labels pulumi.StringMapOutput `pulumi:"labels"`
	// A reference to the zone where the machine resides.
	Location pulumi.StringOutput `pulumi:"location"`
	// A reference to a machine type which defines VM kind.
	MachineType pulumi.StringOutput `pulumi:"machineType"`
	// Custom metadata to apply to this instance.
	// An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
	Metadata pulumi.StringMapOutput `pulumi:"metadata"`
	// The name specified for the Notebook instance.
	Name pulumi.StringOutput `pulumi:"name"`
	// The name of the VPC that this instance is in.
	// Format: projects/{project_id}/global/networks/{network_id}
	Network pulumi.StringOutput `pulumi:"network"`
	// The notebook instance will not register with the proxy..
	NoProxyAccess pulumi.BoolPtrOutput `pulumi:"noProxyAccess"`
	// No public IP will be assigned to this instance.
	NoPublicIp pulumi.BoolPtrOutput `pulumi:"noPublicIp"`
	// If true, the data disk will not be auto deleted when deleting the instance.
	NoRemoveDataDisk pulumi.BoolPtrOutput `pulumi:"noRemoveDataDisk"`
	// Path to a Bash script that automatically runs after a
	// notebook instance fully boots up. The path must be a URL
	// or Cloud Storage path (gs://path-to-file/file-name).
	PostStartupScript pulumi.StringPtrOutput `pulumi:"postStartupScript"`
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project pulumi.StringOutput `pulumi:"project"`
	// The proxy endpoint that is used to access the Jupyter notebook.
	ProxyUri pulumi.StringOutput `pulumi:"proxyUri"`
	// The service account on this instance, giving access to other
	// Google Cloud services. You can use any service account within
	// the same project, but you must have the service account user
	// permission to use the instance. If not specified,
	// the Compute Engine default service account is used.
	ServiceAccount pulumi.StringOutput `pulumi:"serviceAccount"`
	// Optional. The URIs of service account scopes to be included in Compute Engine instances.
	// If not specified, the following scopes are defined:
	// - https://www.googleapis.com/auth/cloud-platform
	// - https://www.googleapis.com/auth/userinfo.email
	ServiceAccountScopes pulumi.StringArrayOutput `pulumi:"serviceAccountScopes"`
	// A set of Shielded Instance options. Check [Images using supported Shielded VM features]
	// Not all combinations are valid
	// Structure is documented below.
	ShieldedInstanceConfig InstanceShieldedInstanceConfigOutput `pulumi:"shieldedInstanceConfig"`
	// The state of this instance.
	State pulumi.StringOutput `pulumi:"state"`
	// The name of the subnet that this instance is in.
	// Format: projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}
	Subnet pulumi.StringOutput `pulumi:"subnet"`
	// The Compute Engine tags to add to runtime.
	Tags pulumi.StringArrayOutput `pulumi:"tags"`
	// Instance update time.
	UpdateTime pulumi.StringOutput `pulumi:"updateTime"`
	// Use a Compute Engine VM image to start the notebook instance.
	// Structure is documented below.
	VmImage InstanceVmImagePtrOutput `pulumi:"vmImage"`
}

A Cloud AI Platform Notebook instance.

> **Note:** Due to limitations of the Notebooks Instance API, many fields in this resource do not properly detect drift. These fields will also not appear in state once imported.

To get more information about Instance, see:

* [API documentation](https://cloud.google.com/ai-platform/notebooks/docs/reference/rest) * How-to Guides

## Example Usage ### Notebook Instance Basic

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstance(ctx, "instance", &notebooks.InstanceArgs{
			Location:    pulumi.String("us-west1-a"),
			MachineType: pulumi.String("e2-medium"),
			VmImage: &notebooks.InstanceVmImageArgs{
				ImageFamily: pulumi.String("tf-latest-cpu"),
				Project:     pulumi.String("deeplearning-platform-release"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

``` ### Notebook Instance Basic Container

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstance(ctx, "instance", &notebooks.InstanceArgs{
			ContainerImage: &notebooks.InstanceContainerImageArgs{
				Repository: pulumi.String("gcr.io/deeplearning-platform-release/base-cpu"),
				Tag:        pulumi.String("latest"),
			},
			Location:    pulumi.String("us-west1-a"),
			MachineType: pulumi.String("e2-medium"),
			Metadata: pulumi.StringMap{
				"proxy-mode": pulumi.String("service_account"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

``` ### Notebook Instance Basic Gpu

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstance(ctx, "instance", &notebooks.InstanceArgs{
			AcceleratorConfig: &notebooks.InstanceAcceleratorConfigArgs{
				CoreCount: pulumi.Int(1),
				Type:      pulumi.String("NVIDIA_TESLA_T4"),
			},
			InstallGpuDriver: pulumi.Bool(true),
			Location:         pulumi.String("us-west1-a"),
			MachineType:      pulumi.String("n1-standard-1"),
			VmImage: &notebooks.InstanceVmImageArgs{
				ImageFamily: pulumi.String("tf-latest-gpu"),
				Project:     pulumi.String("deeplearning-platform-release"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

``` ### Notebook Instance Full

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/compute"
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		myNetwork, err := compute.LookupNetwork(ctx, &compute.LookupNetworkArgs{
			Name: "default",
		}, nil)
		if err != nil {
			return err
		}
		opt0 := "default"
		opt1 := "us-central1"
		mySubnetwork, err := compute.LookupSubnetwork(ctx, &compute.LookupSubnetworkArgs{
			Name:   &opt0,
			Region: &opt1,
		}, nil)
		if err != nil {
			return err
		}
		_, err = notebooks.NewInstance(ctx, "instance", &notebooks.InstanceArgs{
			Location:    pulumi.String("us-central1-a"),
			MachineType: pulumi.String("e2-medium"),
			VmImage: &notebooks.InstanceVmImageArgs{
				Project:     pulumi.String("deeplearning-platform-release"),
				ImageFamily: pulumi.String("tf-latest-cpu"),
			},
			InstanceOwners: pulumi.String(pulumi.String{
				pulumi.String("admin@hashicorptest.com"),
			}),
			ServiceAccount:   pulumi.String("emailAddress:my@service-account.com"),
			InstallGpuDriver: pulumi.Bool(true),
			BootDiskType:     pulumi.String("PD_SSD"),
			BootDiskSizeGb:   pulumi.Int(110),
			NoPublicIp:       pulumi.Bool(true),
			NoProxyAccess:    pulumi.Bool(true),
			Network:          pulumi.String(myNetwork.Id),
			Subnet:           pulumi.String(mySubnetwork.Id),
			Labels: pulumi.StringMap{
				"k": pulumi.String("val"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## Import

Instance can be imported using any of these accepted formats

```sh

$ pulumi import gcp:notebooks/instance:Instance default projects/{{project}}/locations/{{location}}/instances/{{name}}

```

```sh

$ pulumi import gcp:notebooks/instance:Instance default {{project}}/{{location}}/{{name}}

```

```sh

$ pulumi import gcp:notebooks/instance:Instance default {{location}}/{{name}}

```

func GetInstance

func GetInstance(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *InstanceState, opts ...pulumi.ResourceOption) (*Instance, error)

GetInstance gets an existing Instance 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 NewInstance

func NewInstance(ctx *pulumi.Context,
	name string, args *InstanceArgs, opts ...pulumi.ResourceOption) (*Instance, error)

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

func (*Instance) ElementType added in v4.4.0

func (*Instance) ElementType() reflect.Type

func (*Instance) ToInstanceOutput added in v4.4.0

func (i *Instance) ToInstanceOutput() InstanceOutput

func (*Instance) ToInstanceOutputWithContext added in v4.4.0

func (i *Instance) ToInstanceOutputWithContext(ctx context.Context) InstanceOutput

type InstanceAcceleratorConfig

type InstanceAcceleratorConfig struct {
	// Count of cores of this accelerator.
	CoreCount int `pulumi:"coreCount"`
	// Type of this accelerator.
	// Possible values are `ACCELERATOR_TYPE_UNSPECIFIED`, `NVIDIA_TESLA_K80`, `NVIDIA_TESLA_P100`, `NVIDIA_TESLA_V100`, `NVIDIA_TESLA_P4`, `NVIDIA_TESLA_T4`, `NVIDIA_TESLA_T4_VWS`, `NVIDIA_TESLA_P100_VWS`, `NVIDIA_TESLA_P4_VWS`, `NVIDIA_TESLA_A100`, `TPU_V2`, and `TPU_V3`.
	Type string `pulumi:"type"`
}

type InstanceAcceleratorConfigArgs

type InstanceAcceleratorConfigArgs struct {
	// Count of cores of this accelerator.
	CoreCount pulumi.IntInput `pulumi:"coreCount"`
	// Type of this accelerator.
	// Possible values are `ACCELERATOR_TYPE_UNSPECIFIED`, `NVIDIA_TESLA_K80`, `NVIDIA_TESLA_P100`, `NVIDIA_TESLA_V100`, `NVIDIA_TESLA_P4`, `NVIDIA_TESLA_T4`, `NVIDIA_TESLA_T4_VWS`, `NVIDIA_TESLA_P100_VWS`, `NVIDIA_TESLA_P4_VWS`, `NVIDIA_TESLA_A100`, `TPU_V2`, and `TPU_V3`.
	Type pulumi.StringInput `pulumi:"type"`
}

func (InstanceAcceleratorConfigArgs) ElementType

func (InstanceAcceleratorConfigArgs) ToInstanceAcceleratorConfigOutput

func (i InstanceAcceleratorConfigArgs) ToInstanceAcceleratorConfigOutput() InstanceAcceleratorConfigOutput

func (InstanceAcceleratorConfigArgs) ToInstanceAcceleratorConfigOutputWithContext

func (i InstanceAcceleratorConfigArgs) ToInstanceAcceleratorConfigOutputWithContext(ctx context.Context) InstanceAcceleratorConfigOutput

func (InstanceAcceleratorConfigArgs) ToInstanceAcceleratorConfigPtrOutput

func (i InstanceAcceleratorConfigArgs) ToInstanceAcceleratorConfigPtrOutput() InstanceAcceleratorConfigPtrOutput

func (InstanceAcceleratorConfigArgs) ToInstanceAcceleratorConfigPtrOutputWithContext

func (i InstanceAcceleratorConfigArgs) ToInstanceAcceleratorConfigPtrOutputWithContext(ctx context.Context) InstanceAcceleratorConfigPtrOutput

type InstanceAcceleratorConfigInput

type InstanceAcceleratorConfigInput interface {
	pulumi.Input

	ToInstanceAcceleratorConfigOutput() InstanceAcceleratorConfigOutput
	ToInstanceAcceleratorConfigOutputWithContext(context.Context) InstanceAcceleratorConfigOutput
}

InstanceAcceleratorConfigInput is an input type that accepts InstanceAcceleratorConfigArgs and InstanceAcceleratorConfigOutput values. You can construct a concrete instance of `InstanceAcceleratorConfigInput` via:

InstanceAcceleratorConfigArgs{...}

type InstanceAcceleratorConfigOutput

type InstanceAcceleratorConfigOutput struct{ *pulumi.OutputState }

func (InstanceAcceleratorConfigOutput) CoreCount

Count of cores of this accelerator.

func (InstanceAcceleratorConfigOutput) ElementType

func (InstanceAcceleratorConfigOutput) ToInstanceAcceleratorConfigOutput

func (o InstanceAcceleratorConfigOutput) ToInstanceAcceleratorConfigOutput() InstanceAcceleratorConfigOutput

func (InstanceAcceleratorConfigOutput) ToInstanceAcceleratorConfigOutputWithContext

func (o InstanceAcceleratorConfigOutput) ToInstanceAcceleratorConfigOutputWithContext(ctx context.Context) InstanceAcceleratorConfigOutput

func (InstanceAcceleratorConfigOutput) ToInstanceAcceleratorConfigPtrOutput

func (o InstanceAcceleratorConfigOutput) ToInstanceAcceleratorConfigPtrOutput() InstanceAcceleratorConfigPtrOutput

func (InstanceAcceleratorConfigOutput) ToInstanceAcceleratorConfigPtrOutputWithContext

func (o InstanceAcceleratorConfigOutput) ToInstanceAcceleratorConfigPtrOutputWithContext(ctx context.Context) InstanceAcceleratorConfigPtrOutput

func (InstanceAcceleratorConfigOutput) Type

Type of this accelerator. Possible values are `ACCELERATOR_TYPE_UNSPECIFIED`, `NVIDIA_TESLA_K80`, `NVIDIA_TESLA_P100`, `NVIDIA_TESLA_V100`, `NVIDIA_TESLA_P4`, `NVIDIA_TESLA_T4`, `NVIDIA_TESLA_T4_VWS`, `NVIDIA_TESLA_P100_VWS`, `NVIDIA_TESLA_P4_VWS`, `NVIDIA_TESLA_A100`, `TPU_V2`, and `TPU_V3`.

type InstanceAcceleratorConfigPtrInput

type InstanceAcceleratorConfigPtrInput interface {
	pulumi.Input

	ToInstanceAcceleratorConfigPtrOutput() InstanceAcceleratorConfigPtrOutput
	ToInstanceAcceleratorConfigPtrOutputWithContext(context.Context) InstanceAcceleratorConfigPtrOutput
}

InstanceAcceleratorConfigPtrInput is an input type that accepts InstanceAcceleratorConfigArgs, InstanceAcceleratorConfigPtr and InstanceAcceleratorConfigPtrOutput values. You can construct a concrete instance of `InstanceAcceleratorConfigPtrInput` via:

        InstanceAcceleratorConfigArgs{...}

or:

        nil

type InstanceAcceleratorConfigPtrOutput

type InstanceAcceleratorConfigPtrOutput struct{ *pulumi.OutputState }

func (InstanceAcceleratorConfigPtrOutput) CoreCount

Count of cores of this accelerator.

func (InstanceAcceleratorConfigPtrOutput) Elem

func (InstanceAcceleratorConfigPtrOutput) ElementType

func (InstanceAcceleratorConfigPtrOutput) ToInstanceAcceleratorConfigPtrOutput

func (o InstanceAcceleratorConfigPtrOutput) ToInstanceAcceleratorConfigPtrOutput() InstanceAcceleratorConfigPtrOutput

func (InstanceAcceleratorConfigPtrOutput) ToInstanceAcceleratorConfigPtrOutputWithContext

func (o InstanceAcceleratorConfigPtrOutput) ToInstanceAcceleratorConfigPtrOutputWithContext(ctx context.Context) InstanceAcceleratorConfigPtrOutput

func (InstanceAcceleratorConfigPtrOutput) Type

Type of this accelerator. Possible values are `ACCELERATOR_TYPE_UNSPECIFIED`, `NVIDIA_TESLA_K80`, `NVIDIA_TESLA_P100`, `NVIDIA_TESLA_V100`, `NVIDIA_TESLA_P4`, `NVIDIA_TESLA_T4`, `NVIDIA_TESLA_T4_VWS`, `NVIDIA_TESLA_P100_VWS`, `NVIDIA_TESLA_P4_VWS`, `NVIDIA_TESLA_A100`, `TPU_V2`, and `TPU_V3`.

type InstanceArgs

type InstanceArgs struct {
	// The hardware accelerator used on this instance. If you use accelerators,
	// make sure that your configuration has enough vCPUs and memory to support the
	// machineType you have selected.
	// Structure is documented below.
	AcceleratorConfig InstanceAcceleratorConfigPtrInput
	// The size of the boot disk in GB attached to this instance,
	// up to a maximum of 64000 GB (64 TB). The minimum recommended value is 100 GB.
	// If not specified, this defaults to 100.
	BootDiskSizeGb pulumi.IntPtrInput
	// Possible disk types for notebook instances.
	// Possible values are `DISK_TYPE_UNSPECIFIED`, `PD_STANDARD`, `PD_SSD`, and `PD_BALANCED`.
	BootDiskType pulumi.StringPtrInput
	// Use a container image to start the notebook instance.
	// Structure is documented below.
	ContainerImage InstanceContainerImagePtrInput
	// Instance creation time
	CreateTime pulumi.StringPtrInput
	// Specify a custom Cloud Storage path where the GPU driver is stored.
	// If not specified, we'll automatically choose from official GPU drivers.
	CustomGpuDriverPath pulumi.StringPtrInput
	// The size of the data disk in GB attached to this instance,
	// up to a maximum of 64000 GB (64 TB).
	// You can choose the size of the data disk based on how big your notebooks and data are.
	// If not specified, this defaults to 100.
	DataDiskSizeGb pulumi.IntPtrInput
	// Possible disk types for notebook instances.
	// Possible values are `DISK_TYPE_UNSPECIFIED`, `PD_STANDARD`, `PD_SSD`, and `PD_BALANCED`.
	DataDiskType pulumi.StringPtrInput
	// Disk encryption method used on the boot and data disks, defaults to GMEK.
	// Possible values are `DISK_ENCRYPTION_UNSPECIFIED`, `GMEK`, and `CMEK`.
	DiskEncryption pulumi.StringPtrInput
	// Whether the end user authorizes Google Cloud to install GPU driver
	// on this instance. If this field is empty or set to false, the GPU driver
	// won't be installed. Only applicable to instances with GPUs.
	InstallGpuDriver pulumi.BoolPtrInput
	// The list of owners of this instance after creation.
	// Format: alias@example.com.
	// Currently supports one owner only.
	// If not specified, all of the service account users of
	// your VM instance's service account can use the instance.
	InstanceOwners pulumi.StringPtrInput
	// The KMS key used to encrypt the disks, only applicable if diskEncryption is CMEK.
	// Format: projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}
	KmsKey pulumi.StringPtrInput
	// Labels to apply to this instance. These can be later modified by the setLabels method.
	// An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
	Labels pulumi.StringMapInput
	// A reference to the zone where the machine resides.
	Location pulumi.StringInput
	// A reference to a machine type which defines VM kind.
	MachineType pulumi.StringInput
	// Custom metadata to apply to this instance.
	// An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
	Metadata pulumi.StringMapInput
	// The name specified for the Notebook instance.
	Name pulumi.StringPtrInput
	// The name of the VPC that this instance is in.
	// Format: projects/{project_id}/global/networks/{network_id}
	Network pulumi.StringPtrInput
	// The notebook instance will not register with the proxy..
	NoProxyAccess pulumi.BoolPtrInput
	// No public IP will be assigned to this instance.
	NoPublicIp pulumi.BoolPtrInput
	// If true, the data disk will not be auto deleted when deleting the instance.
	NoRemoveDataDisk pulumi.BoolPtrInput
	// Path to a Bash script that automatically runs after a
	// notebook instance fully boots up. The path must be a URL
	// or Cloud Storage path (gs://path-to-file/file-name).
	PostStartupScript pulumi.StringPtrInput
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project pulumi.StringPtrInput
	// The service account on this instance, giving access to other
	// Google Cloud services. You can use any service account within
	// the same project, but you must have the service account user
	// permission to use the instance. If not specified,
	// the Compute Engine default service account is used.
	ServiceAccount pulumi.StringPtrInput
	// Optional. The URIs of service account scopes to be included in Compute Engine instances.
	// If not specified, the following scopes are defined:
	// - https://www.googleapis.com/auth/cloud-platform
	// - https://www.googleapis.com/auth/userinfo.email
	ServiceAccountScopes pulumi.StringArrayInput
	// A set of Shielded Instance options. Check [Images using supported Shielded VM features]
	// Not all combinations are valid
	// Structure is documented below.
	ShieldedInstanceConfig InstanceShieldedInstanceConfigPtrInput
	// The name of the subnet that this instance is in.
	// Format: projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}
	Subnet pulumi.StringPtrInput
	// The Compute Engine tags to add to runtime.
	Tags pulumi.StringArrayInput
	// Instance update time.
	UpdateTime pulumi.StringPtrInput
	// Use a Compute Engine VM image to start the notebook instance.
	// Structure is documented below.
	VmImage InstanceVmImagePtrInput
}

The set of arguments for constructing a Instance resource.

func (InstanceArgs) ElementType

func (InstanceArgs) ElementType() reflect.Type

type InstanceContainerImage

type InstanceContainerImage struct {
	// The path to the container image repository.
	// For example: gcr.io/{project_id}/{imageName}
	Repository string `pulumi:"repository"`
	// The tag of the container image. If not specified, this defaults to the latest tag.
	Tag *string `pulumi:"tag"`
}

type InstanceContainerImageArgs

type InstanceContainerImageArgs struct {
	// The path to the container image repository.
	// For example: gcr.io/{project_id}/{imageName}
	Repository pulumi.StringInput `pulumi:"repository"`
	// The tag of the container image. If not specified, this defaults to the latest tag.
	Tag pulumi.StringPtrInput `pulumi:"tag"`
}

func (InstanceContainerImageArgs) ElementType

func (InstanceContainerImageArgs) ElementType() reflect.Type

func (InstanceContainerImageArgs) ToInstanceContainerImageOutput

func (i InstanceContainerImageArgs) ToInstanceContainerImageOutput() InstanceContainerImageOutput

func (InstanceContainerImageArgs) ToInstanceContainerImageOutputWithContext

func (i InstanceContainerImageArgs) ToInstanceContainerImageOutputWithContext(ctx context.Context) InstanceContainerImageOutput

func (InstanceContainerImageArgs) ToInstanceContainerImagePtrOutput

func (i InstanceContainerImageArgs) ToInstanceContainerImagePtrOutput() InstanceContainerImagePtrOutput

func (InstanceContainerImageArgs) ToInstanceContainerImagePtrOutputWithContext

func (i InstanceContainerImageArgs) ToInstanceContainerImagePtrOutputWithContext(ctx context.Context) InstanceContainerImagePtrOutput

type InstanceContainerImageInput

type InstanceContainerImageInput interface {
	pulumi.Input

	ToInstanceContainerImageOutput() InstanceContainerImageOutput
	ToInstanceContainerImageOutputWithContext(context.Context) InstanceContainerImageOutput
}

InstanceContainerImageInput is an input type that accepts InstanceContainerImageArgs and InstanceContainerImageOutput values. You can construct a concrete instance of `InstanceContainerImageInput` via:

InstanceContainerImageArgs{...}

type InstanceContainerImageOutput

type InstanceContainerImageOutput struct{ *pulumi.OutputState }

func (InstanceContainerImageOutput) ElementType

func (InstanceContainerImageOutput) Repository

The path to the container image repository. For example: gcr.io/{project_id}/{imageName}

func (InstanceContainerImageOutput) Tag

The tag of the container image. If not specified, this defaults to the latest tag.

func (InstanceContainerImageOutput) ToInstanceContainerImageOutput

func (o InstanceContainerImageOutput) ToInstanceContainerImageOutput() InstanceContainerImageOutput

func (InstanceContainerImageOutput) ToInstanceContainerImageOutputWithContext

func (o InstanceContainerImageOutput) ToInstanceContainerImageOutputWithContext(ctx context.Context) InstanceContainerImageOutput

func (InstanceContainerImageOutput) ToInstanceContainerImagePtrOutput

func (o InstanceContainerImageOutput) ToInstanceContainerImagePtrOutput() InstanceContainerImagePtrOutput

func (InstanceContainerImageOutput) ToInstanceContainerImagePtrOutputWithContext

func (o InstanceContainerImageOutput) ToInstanceContainerImagePtrOutputWithContext(ctx context.Context) InstanceContainerImagePtrOutput

type InstanceContainerImagePtrInput

type InstanceContainerImagePtrInput interface {
	pulumi.Input

	ToInstanceContainerImagePtrOutput() InstanceContainerImagePtrOutput
	ToInstanceContainerImagePtrOutputWithContext(context.Context) InstanceContainerImagePtrOutput
}

InstanceContainerImagePtrInput is an input type that accepts InstanceContainerImageArgs, InstanceContainerImagePtr and InstanceContainerImagePtrOutput values. You can construct a concrete instance of `InstanceContainerImagePtrInput` via:

        InstanceContainerImageArgs{...}

or:

        nil

type InstanceContainerImagePtrOutput

type InstanceContainerImagePtrOutput struct{ *pulumi.OutputState }

func (InstanceContainerImagePtrOutput) Elem

func (InstanceContainerImagePtrOutput) ElementType

func (InstanceContainerImagePtrOutput) Repository

The path to the container image repository. For example: gcr.io/{project_id}/{imageName}

func (InstanceContainerImagePtrOutput) Tag

The tag of the container image. If not specified, this defaults to the latest tag.

func (InstanceContainerImagePtrOutput) ToInstanceContainerImagePtrOutput

func (o InstanceContainerImagePtrOutput) ToInstanceContainerImagePtrOutput() InstanceContainerImagePtrOutput

func (InstanceContainerImagePtrOutput) ToInstanceContainerImagePtrOutputWithContext

func (o InstanceContainerImagePtrOutput) ToInstanceContainerImagePtrOutputWithContext(ctx context.Context) InstanceContainerImagePtrOutput

type InstanceIamBinding added in v4.1.0

type InstanceIamBinding struct {
	pulumi.CustomResourceState

	Condition InstanceIamBindingConditionPtrOutput `pulumi:"condition"`
	// (Computed) The etag of the IAM policy.
	Etag pulumi.StringOutput `pulumi:"etag"`
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringOutput `pulumi:"instanceName"`
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringOutput      `pulumi:"location"`
	Members  pulumi.StringArrayOutput `pulumi:"members"`
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringOutput `pulumi:"project"`
	// The role that should be applied. Only one
	// `notebooks.InstanceIamBinding` can be used per role. Note that custom roles must be of the format
	// `[projects|organizations]/{parent-name}/roles/{role-name}`.
	Role pulumi.StringOutput `pulumi:"role"`
}

Three different resources help you manage your IAM policy for Cloud AI Notebooks Instance. Each of these resources serves a different use case:

* `notebooks.InstanceIamPolicy`: Authoritative. Sets the IAM policy for the instance and replaces any existing policy already attached. * `notebooks.InstanceIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the instance are preserved. * `notebooks.InstanceIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the instance are preserved.

> **Note:** `notebooks.InstanceIamPolicy` **cannot** be used in conjunction with `notebooks.InstanceIamBinding` and `notebooks.InstanceIamMember` or they will fight over what your policy should be.

> **Note:** `notebooks.InstanceIamBinding` resources **can be** used in conjunction with `notebooks.InstanceIamMember` resources **only if** they do not grant privilege to the same role.

## google\_notebooks\_instance\_iam\_policy

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{
			Bindings: []organizations.GetIAMPolicyBinding{
				organizations.GetIAMPolicyBinding{
					Role: "roles/viewer",
					Members: []string{
						"user:jane@example.com",
					},
				},
			},
		}, nil)
		if err != nil {
			return err
		}
		_, err = notebooks.NewInstanceIamPolicy(ctx, "policy", &notebooks.InstanceIamPolicyArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			PolicyData:   pulumi.String(admin.PolicyData),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## google\_notebooks\_instance\_iam\_binding

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstanceIamBinding(ctx, "binding", &notebooks.InstanceIamBindingArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			Role:         pulumi.String("roles/viewer"),
			Members: pulumi.StringArray{
				pulumi.String("user:jane@example.com"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## google\_notebooks\_instance\_iam\_member

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstanceIamMember(ctx, "member", &notebooks.InstanceIamMemberArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			Role:         pulumi.String("roles/viewer"),
			Member:       pulumi.String("user:jane@example.com"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## Import

For all import syntaxes, the "resource in question" can take any of the following forms* projects/{{project}}/locations/{{location}}/instances/{{instance_name}} * {{project}}/{{location}}/{{instance_name}} * {{location}}/{{instance_name}} * {{instance_name}} Any variables not passed in the import command will be taken from the provider configuration. Cloud AI Notebooks instance IAM resources can be imported using the resource identifiers, role, and member. IAM member imports use space-delimited identifiersthe resource in question, the role, and the member identity, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamBinding:InstanceIamBinding editor "projects/{{project}}/locations/{{location}}/instances/{{instance_name}} roles/viewer user:jane@example.com"

```

IAM binding imports use space-delimited identifiersthe resource in question and the role, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamBinding:InstanceIamBinding editor "projects/{{project}}/locations/{{location}}/instances/{{instance_name}} roles/viewer"

```

IAM policy imports use the identifier of the resource in question, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamBinding:InstanceIamBinding editor projects/{{project}}/locations/{{location}}/instances/{{instance_name}}

```

-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the

full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.

func GetInstanceIamBinding added in v4.1.0

func GetInstanceIamBinding(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *InstanceIamBindingState, opts ...pulumi.ResourceOption) (*InstanceIamBinding, error)

GetInstanceIamBinding gets an existing InstanceIamBinding 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 NewInstanceIamBinding added in v4.1.0

func NewInstanceIamBinding(ctx *pulumi.Context,
	name string, args *InstanceIamBindingArgs, opts ...pulumi.ResourceOption) (*InstanceIamBinding, error)

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

func (*InstanceIamBinding) ElementType added in v4.4.0

func (*InstanceIamBinding) ElementType() reflect.Type

func (*InstanceIamBinding) ToInstanceIamBindingOutput added in v4.4.0

func (i *InstanceIamBinding) ToInstanceIamBindingOutput() InstanceIamBindingOutput

func (*InstanceIamBinding) ToInstanceIamBindingOutputWithContext added in v4.4.0

func (i *InstanceIamBinding) ToInstanceIamBindingOutputWithContext(ctx context.Context) InstanceIamBindingOutput

type InstanceIamBindingArgs added in v4.1.0

type InstanceIamBindingArgs struct {
	Condition InstanceIamBindingConditionPtrInput
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringInput
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringPtrInput
	Members  pulumi.StringArrayInput
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringPtrInput
	// The role that should be applied. Only one
	// `notebooks.InstanceIamBinding` can be used per role. Note that custom roles must be of the format
	// `[projects|organizations]/{parent-name}/roles/{role-name}`.
	Role pulumi.StringInput
}

The set of arguments for constructing a InstanceIamBinding resource.

func (InstanceIamBindingArgs) ElementType added in v4.1.0

func (InstanceIamBindingArgs) ElementType() reflect.Type

type InstanceIamBindingCondition added in v4.1.0

type InstanceIamBindingCondition struct {
	Description *string `pulumi:"description"`
	Expression  string  `pulumi:"expression"`
	Title       string  `pulumi:"title"`
}

type InstanceIamBindingConditionArgs added in v4.1.0

type InstanceIamBindingConditionArgs struct {
	Description pulumi.StringPtrInput `pulumi:"description"`
	Expression  pulumi.StringInput    `pulumi:"expression"`
	Title       pulumi.StringInput    `pulumi:"title"`
}

func (InstanceIamBindingConditionArgs) ElementType added in v4.1.0

func (InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutput added in v4.1.0

func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutput() InstanceIamBindingConditionOutput

func (InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutputWithContext added in v4.1.0

func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutputWithContext(ctx context.Context) InstanceIamBindingConditionOutput

func (InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutput added in v4.1.0

func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput

func (InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutputWithContext added in v4.1.0

func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput

type InstanceIamBindingConditionInput added in v4.1.0

type InstanceIamBindingConditionInput interface {
	pulumi.Input

	ToInstanceIamBindingConditionOutput() InstanceIamBindingConditionOutput
	ToInstanceIamBindingConditionOutputWithContext(context.Context) InstanceIamBindingConditionOutput
}

InstanceIamBindingConditionInput is an input type that accepts InstanceIamBindingConditionArgs and InstanceIamBindingConditionOutput values. You can construct a concrete instance of `InstanceIamBindingConditionInput` via:

InstanceIamBindingConditionArgs{...}

type InstanceIamBindingConditionOutput added in v4.1.0

type InstanceIamBindingConditionOutput struct{ *pulumi.OutputState }

func (InstanceIamBindingConditionOutput) Description added in v4.1.0

func (InstanceIamBindingConditionOutput) ElementType added in v4.1.0

func (InstanceIamBindingConditionOutput) Expression added in v4.1.0

func (InstanceIamBindingConditionOutput) Title added in v4.1.0

func (InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutput added in v4.1.0

func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutput() InstanceIamBindingConditionOutput

func (InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutputWithContext added in v4.1.0

func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutputWithContext(ctx context.Context) InstanceIamBindingConditionOutput

func (InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutput added in v4.1.0

func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput

func (InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutputWithContext added in v4.1.0

func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput

type InstanceIamBindingConditionPtrInput added in v4.1.0

type InstanceIamBindingConditionPtrInput interface {
	pulumi.Input

	ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput
	ToInstanceIamBindingConditionPtrOutputWithContext(context.Context) InstanceIamBindingConditionPtrOutput
}

InstanceIamBindingConditionPtrInput is an input type that accepts InstanceIamBindingConditionArgs, InstanceIamBindingConditionPtr and InstanceIamBindingConditionPtrOutput values. You can construct a concrete instance of `InstanceIamBindingConditionPtrInput` via:

        InstanceIamBindingConditionArgs{...}

or:

        nil

func InstanceIamBindingConditionPtr added in v4.1.0

type InstanceIamBindingConditionPtrOutput added in v4.1.0

type InstanceIamBindingConditionPtrOutput struct{ *pulumi.OutputState }

func (InstanceIamBindingConditionPtrOutput) Description added in v4.1.0

func (InstanceIamBindingConditionPtrOutput) Elem added in v4.1.0

func (InstanceIamBindingConditionPtrOutput) ElementType added in v4.1.0

func (InstanceIamBindingConditionPtrOutput) Expression added in v4.1.0

func (InstanceIamBindingConditionPtrOutput) Title added in v4.1.0

func (InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutput added in v4.1.0

func (o InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput

func (InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutputWithContext added in v4.1.0

func (o InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput

type InstanceIamBindingInput added in v4.4.0

type InstanceIamBindingInput interface {
	pulumi.Input

	ToInstanceIamBindingOutput() InstanceIamBindingOutput
	ToInstanceIamBindingOutputWithContext(ctx context.Context) InstanceIamBindingOutput
}

type InstanceIamBindingOutput added in v4.4.0

type InstanceIamBindingOutput struct {
	*pulumi.OutputState
}

func (InstanceIamBindingOutput) ElementType added in v4.4.0

func (InstanceIamBindingOutput) ElementType() reflect.Type

func (InstanceIamBindingOutput) ToInstanceIamBindingOutput added in v4.4.0

func (o InstanceIamBindingOutput) ToInstanceIamBindingOutput() InstanceIamBindingOutput

func (InstanceIamBindingOutput) ToInstanceIamBindingOutputWithContext added in v4.4.0

func (o InstanceIamBindingOutput) ToInstanceIamBindingOutputWithContext(ctx context.Context) InstanceIamBindingOutput

type InstanceIamBindingState added in v4.1.0

type InstanceIamBindingState struct {
	Condition InstanceIamBindingConditionPtrInput
	// (Computed) The etag of the IAM policy.
	Etag pulumi.StringPtrInput
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringPtrInput
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringPtrInput
	Members  pulumi.StringArrayInput
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringPtrInput
	// The role that should be applied. Only one
	// `notebooks.InstanceIamBinding` can be used per role. Note that custom roles must be of the format
	// `[projects|organizations]/{parent-name}/roles/{role-name}`.
	Role pulumi.StringPtrInput
}

func (InstanceIamBindingState) ElementType added in v4.1.0

func (InstanceIamBindingState) ElementType() reflect.Type

type InstanceIamMember added in v4.1.0

type InstanceIamMember struct {
	pulumi.CustomResourceState

	Condition InstanceIamMemberConditionPtrOutput `pulumi:"condition"`
	// (Computed) The etag of the IAM policy.
	Etag pulumi.StringOutput `pulumi:"etag"`
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringOutput `pulumi:"instanceName"`
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringOutput `pulumi:"location"`
	Member   pulumi.StringOutput `pulumi:"member"`
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringOutput `pulumi:"project"`
	// The role that should be applied. Only one
	// `notebooks.InstanceIamBinding` can be used per role. Note that custom roles must be of the format
	// `[projects|organizations]/{parent-name}/roles/{role-name}`.
	Role pulumi.StringOutput `pulumi:"role"`
}

Three different resources help you manage your IAM policy for Cloud AI Notebooks Instance. Each of these resources serves a different use case:

* `notebooks.InstanceIamPolicy`: Authoritative. Sets the IAM policy for the instance and replaces any existing policy already attached. * `notebooks.InstanceIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the instance are preserved. * `notebooks.InstanceIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the instance are preserved.

> **Note:** `notebooks.InstanceIamPolicy` **cannot** be used in conjunction with `notebooks.InstanceIamBinding` and `notebooks.InstanceIamMember` or they will fight over what your policy should be.

> **Note:** `notebooks.InstanceIamBinding` resources **can be** used in conjunction with `notebooks.InstanceIamMember` resources **only if** they do not grant privilege to the same role.

## google\_notebooks\_instance\_iam\_policy

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{
			Bindings: []organizations.GetIAMPolicyBinding{
				organizations.GetIAMPolicyBinding{
					Role: "roles/viewer",
					Members: []string{
						"user:jane@example.com",
					},
				},
			},
		}, nil)
		if err != nil {
			return err
		}
		_, err = notebooks.NewInstanceIamPolicy(ctx, "policy", &notebooks.InstanceIamPolicyArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			PolicyData:   pulumi.String(admin.PolicyData),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## google\_notebooks\_instance\_iam\_binding

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstanceIamBinding(ctx, "binding", &notebooks.InstanceIamBindingArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			Role:         pulumi.String("roles/viewer"),
			Members: pulumi.StringArray{
				pulumi.String("user:jane@example.com"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## google\_notebooks\_instance\_iam\_member

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstanceIamMember(ctx, "member", &notebooks.InstanceIamMemberArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			Role:         pulumi.String("roles/viewer"),
			Member:       pulumi.String("user:jane@example.com"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## Import

For all import syntaxes, the "resource in question" can take any of the following forms* projects/{{project}}/locations/{{location}}/instances/{{instance_name}} * {{project}}/{{location}}/{{instance_name}} * {{location}}/{{instance_name}} * {{instance_name}} Any variables not passed in the import command will be taken from the provider configuration. Cloud AI Notebooks instance IAM resources can be imported using the resource identifiers, role, and member. IAM member imports use space-delimited identifiersthe resource in question, the role, and the member identity, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamMember:InstanceIamMember editor "projects/{{project}}/locations/{{location}}/instances/{{instance_name}} roles/viewer user:jane@example.com"

```

IAM binding imports use space-delimited identifiersthe resource in question and the role, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamMember:InstanceIamMember editor "projects/{{project}}/locations/{{location}}/instances/{{instance_name}} roles/viewer"

```

IAM policy imports use the identifier of the resource in question, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamMember:InstanceIamMember editor projects/{{project}}/locations/{{location}}/instances/{{instance_name}}

```

-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the

full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.

func GetInstanceIamMember added in v4.1.0

func GetInstanceIamMember(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *InstanceIamMemberState, opts ...pulumi.ResourceOption) (*InstanceIamMember, error)

GetInstanceIamMember gets an existing InstanceIamMember 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 NewInstanceIamMember added in v4.1.0

func NewInstanceIamMember(ctx *pulumi.Context,
	name string, args *InstanceIamMemberArgs, opts ...pulumi.ResourceOption) (*InstanceIamMember, error)

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

func (*InstanceIamMember) ElementType added in v4.4.0

func (*InstanceIamMember) ElementType() reflect.Type

func (*InstanceIamMember) ToInstanceIamMemberOutput added in v4.4.0

func (i *InstanceIamMember) ToInstanceIamMemberOutput() InstanceIamMemberOutput

func (*InstanceIamMember) ToInstanceIamMemberOutputWithContext added in v4.4.0

func (i *InstanceIamMember) ToInstanceIamMemberOutputWithContext(ctx context.Context) InstanceIamMemberOutput

type InstanceIamMemberArgs added in v4.1.0

type InstanceIamMemberArgs struct {
	Condition InstanceIamMemberConditionPtrInput
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringInput
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringPtrInput
	Member   pulumi.StringInput
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringPtrInput
	// The role that should be applied. Only one
	// `notebooks.InstanceIamBinding` can be used per role. Note that custom roles must be of the format
	// `[projects|organizations]/{parent-name}/roles/{role-name}`.
	Role pulumi.StringInput
}

The set of arguments for constructing a InstanceIamMember resource.

func (InstanceIamMemberArgs) ElementType added in v4.1.0

func (InstanceIamMemberArgs) ElementType() reflect.Type

type InstanceIamMemberCondition added in v4.1.0

type InstanceIamMemberCondition struct {
	Description *string `pulumi:"description"`
	Expression  string  `pulumi:"expression"`
	Title       string  `pulumi:"title"`
}

type InstanceIamMemberConditionArgs added in v4.1.0

type InstanceIamMemberConditionArgs struct {
	Description pulumi.StringPtrInput `pulumi:"description"`
	Expression  pulumi.StringInput    `pulumi:"expression"`
	Title       pulumi.StringInput    `pulumi:"title"`
}

func (InstanceIamMemberConditionArgs) ElementType added in v4.1.0

func (InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutput added in v4.1.0

func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutput() InstanceIamMemberConditionOutput

func (InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutputWithContext added in v4.1.0

func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutputWithContext(ctx context.Context) InstanceIamMemberConditionOutput

func (InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutput added in v4.1.0

func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput

func (InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutputWithContext added in v4.1.0

func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput

type InstanceIamMemberConditionInput added in v4.1.0

type InstanceIamMemberConditionInput interface {
	pulumi.Input

	ToInstanceIamMemberConditionOutput() InstanceIamMemberConditionOutput
	ToInstanceIamMemberConditionOutputWithContext(context.Context) InstanceIamMemberConditionOutput
}

InstanceIamMemberConditionInput is an input type that accepts InstanceIamMemberConditionArgs and InstanceIamMemberConditionOutput values. You can construct a concrete instance of `InstanceIamMemberConditionInput` via:

InstanceIamMemberConditionArgs{...}

type InstanceIamMemberConditionOutput added in v4.1.0

type InstanceIamMemberConditionOutput struct{ *pulumi.OutputState }

func (InstanceIamMemberConditionOutput) Description added in v4.1.0

func (InstanceIamMemberConditionOutput) ElementType added in v4.1.0

func (InstanceIamMemberConditionOutput) Expression added in v4.1.0

func (InstanceIamMemberConditionOutput) Title added in v4.1.0

func (InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutput added in v4.1.0

func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutput() InstanceIamMemberConditionOutput

func (InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutputWithContext added in v4.1.0

func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutputWithContext(ctx context.Context) InstanceIamMemberConditionOutput

func (InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutput added in v4.1.0

func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput

func (InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutputWithContext added in v4.1.0

func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput

type InstanceIamMemberConditionPtrInput added in v4.1.0

type InstanceIamMemberConditionPtrInput interface {
	pulumi.Input

	ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput
	ToInstanceIamMemberConditionPtrOutputWithContext(context.Context) InstanceIamMemberConditionPtrOutput
}

InstanceIamMemberConditionPtrInput is an input type that accepts InstanceIamMemberConditionArgs, InstanceIamMemberConditionPtr and InstanceIamMemberConditionPtrOutput values. You can construct a concrete instance of `InstanceIamMemberConditionPtrInput` via:

        InstanceIamMemberConditionArgs{...}

or:

        nil

func InstanceIamMemberConditionPtr added in v4.1.0

type InstanceIamMemberConditionPtrOutput added in v4.1.0

type InstanceIamMemberConditionPtrOutput struct{ *pulumi.OutputState }

func (InstanceIamMemberConditionPtrOutput) Description added in v4.1.0

func (InstanceIamMemberConditionPtrOutput) Elem added in v4.1.0

func (InstanceIamMemberConditionPtrOutput) ElementType added in v4.1.0

func (InstanceIamMemberConditionPtrOutput) Expression added in v4.1.0

func (InstanceIamMemberConditionPtrOutput) Title added in v4.1.0

func (InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutput added in v4.1.0

func (o InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput

func (InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutputWithContext added in v4.1.0

func (o InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput

type InstanceIamMemberInput added in v4.4.0

type InstanceIamMemberInput interface {
	pulumi.Input

	ToInstanceIamMemberOutput() InstanceIamMemberOutput
	ToInstanceIamMemberOutputWithContext(ctx context.Context) InstanceIamMemberOutput
}

type InstanceIamMemberOutput added in v4.4.0

type InstanceIamMemberOutput struct {
	*pulumi.OutputState
}

func (InstanceIamMemberOutput) ElementType added in v4.4.0

func (InstanceIamMemberOutput) ElementType() reflect.Type

func (InstanceIamMemberOutput) ToInstanceIamMemberOutput added in v4.4.0

func (o InstanceIamMemberOutput) ToInstanceIamMemberOutput() InstanceIamMemberOutput

func (InstanceIamMemberOutput) ToInstanceIamMemberOutputWithContext added in v4.4.0

func (o InstanceIamMemberOutput) ToInstanceIamMemberOutputWithContext(ctx context.Context) InstanceIamMemberOutput

type InstanceIamMemberState added in v4.1.0

type InstanceIamMemberState struct {
	Condition InstanceIamMemberConditionPtrInput
	// (Computed) The etag of the IAM policy.
	Etag pulumi.StringPtrInput
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringPtrInput
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringPtrInput
	Member   pulumi.StringPtrInput
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringPtrInput
	// The role that should be applied. Only one
	// `notebooks.InstanceIamBinding` can be used per role. Note that custom roles must be of the format
	// `[projects|organizations]/{parent-name}/roles/{role-name}`.
	Role pulumi.StringPtrInput
}

func (InstanceIamMemberState) ElementType added in v4.1.0

func (InstanceIamMemberState) ElementType() reflect.Type

type InstanceIamPolicy added in v4.1.0

type InstanceIamPolicy struct {
	pulumi.CustomResourceState

	// (Computed) The etag of the IAM policy.
	Etag pulumi.StringOutput `pulumi:"etag"`
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringOutput `pulumi:"instanceName"`
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringOutput `pulumi:"location"`
	// The policy data generated by
	// a `organizations.getIAMPolicy` data source.
	PolicyData pulumi.StringOutput `pulumi:"policyData"`
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringOutput `pulumi:"project"`
}

Three different resources help you manage your IAM policy for Cloud AI Notebooks Instance. Each of these resources serves a different use case:

* `notebooks.InstanceIamPolicy`: Authoritative. Sets the IAM policy for the instance and replaces any existing policy already attached. * `notebooks.InstanceIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the instance are preserved. * `notebooks.InstanceIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the instance are preserved.

> **Note:** `notebooks.InstanceIamPolicy` **cannot** be used in conjunction with `notebooks.InstanceIamBinding` and `notebooks.InstanceIamMember` or they will fight over what your policy should be.

> **Note:** `notebooks.InstanceIamBinding` resources **can be** used in conjunction with `notebooks.InstanceIamMember` resources **only if** they do not grant privilege to the same role.

## google\_notebooks\_instance\_iam\_policy

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{
			Bindings: []organizations.GetIAMPolicyBinding{
				organizations.GetIAMPolicyBinding{
					Role: "roles/viewer",
					Members: []string{
						"user:jane@example.com",
					},
				},
			},
		}, nil)
		if err != nil {
			return err
		}
		_, err = notebooks.NewInstanceIamPolicy(ctx, "policy", &notebooks.InstanceIamPolicyArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			PolicyData:   pulumi.String(admin.PolicyData),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## google\_notebooks\_instance\_iam\_binding

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstanceIamBinding(ctx, "binding", &notebooks.InstanceIamBindingArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			Role:         pulumi.String("roles/viewer"),
			Members: pulumi.StringArray{
				pulumi.String("user:jane@example.com"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## google\_notebooks\_instance\_iam\_member

```go package main

import (

"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/notebooks"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := notebooks.NewInstanceIamMember(ctx, "member", &notebooks.InstanceIamMemberArgs{
			Project:      pulumi.Any(google_notebooks_instance.Instance.Project),
			Location:     pulumi.Any(google_notebooks_instance.Instance.Location),
			InstanceName: pulumi.Any(google_notebooks_instance.Instance.Name),
			Role:         pulumi.String("roles/viewer"),
			Member:       pulumi.String("user:jane@example.com"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## Import

For all import syntaxes, the "resource in question" can take any of the following forms* projects/{{project}}/locations/{{location}}/instances/{{instance_name}} * {{project}}/{{location}}/{{instance_name}} * {{location}}/{{instance_name}} * {{instance_name}} Any variables not passed in the import command will be taken from the provider configuration. Cloud AI Notebooks instance IAM resources can be imported using the resource identifiers, role, and member. IAM member imports use space-delimited identifiersthe resource in question, the role, and the member identity, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamPolicy:InstanceIamPolicy editor "projects/{{project}}/locations/{{location}}/instances/{{instance_name}} roles/viewer user:jane@example.com"

```

IAM binding imports use space-delimited identifiersthe resource in question and the role, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamPolicy:InstanceIamPolicy editor "projects/{{project}}/locations/{{location}}/instances/{{instance_name}} roles/viewer"

```

IAM policy imports use the identifier of the resource in question, e.g.

```sh

$ pulumi import gcp:notebooks/instanceIamPolicy:InstanceIamPolicy editor projects/{{project}}/locations/{{location}}/instances/{{instance_name}}

```

-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the

full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.

func GetInstanceIamPolicy added in v4.1.0

func GetInstanceIamPolicy(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *InstanceIamPolicyState, opts ...pulumi.ResourceOption) (*InstanceIamPolicy, error)

GetInstanceIamPolicy gets an existing InstanceIamPolicy 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 NewInstanceIamPolicy added in v4.1.0

func NewInstanceIamPolicy(ctx *pulumi.Context,
	name string, args *InstanceIamPolicyArgs, opts ...pulumi.ResourceOption) (*InstanceIamPolicy, error)

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

func (*InstanceIamPolicy) ElementType added in v4.4.0

func (*InstanceIamPolicy) ElementType() reflect.Type

func (*InstanceIamPolicy) ToInstanceIamPolicyOutput added in v4.4.0

func (i *InstanceIamPolicy) ToInstanceIamPolicyOutput() InstanceIamPolicyOutput

func (*InstanceIamPolicy) ToInstanceIamPolicyOutputWithContext added in v4.4.0

func (i *InstanceIamPolicy) ToInstanceIamPolicyOutputWithContext(ctx context.Context) InstanceIamPolicyOutput

type InstanceIamPolicyArgs added in v4.1.0

type InstanceIamPolicyArgs struct {
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringInput
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringPtrInput
	// The policy data generated by
	// a `organizations.getIAMPolicy` data source.
	PolicyData pulumi.StringInput
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringPtrInput
}

The set of arguments for constructing a InstanceIamPolicy resource.

func (InstanceIamPolicyArgs) ElementType added in v4.1.0

func (InstanceIamPolicyArgs) ElementType() reflect.Type

type InstanceIamPolicyInput added in v4.4.0

type InstanceIamPolicyInput interface {
	pulumi.Input

	ToInstanceIamPolicyOutput() InstanceIamPolicyOutput
	ToInstanceIamPolicyOutputWithContext(ctx context.Context) InstanceIamPolicyOutput
}

type InstanceIamPolicyOutput added in v4.4.0

type InstanceIamPolicyOutput struct {
	*pulumi.OutputState
}

func (InstanceIamPolicyOutput) ElementType added in v4.4.0

func (InstanceIamPolicyOutput) ElementType() reflect.Type

func (InstanceIamPolicyOutput) ToInstanceIamPolicyOutput added in v4.4.0

func (o InstanceIamPolicyOutput) ToInstanceIamPolicyOutput() InstanceIamPolicyOutput

func (InstanceIamPolicyOutput) ToInstanceIamPolicyOutputWithContext added in v4.4.0

func (o InstanceIamPolicyOutput) ToInstanceIamPolicyOutputWithContext(ctx context.Context) InstanceIamPolicyOutput

type InstanceIamPolicyState added in v4.1.0

type InstanceIamPolicyState struct {
	// (Computed) The etag of the IAM policy.
	Etag pulumi.StringPtrInput
	// Used to find the parent resource to bind the IAM policy to
	InstanceName pulumi.StringPtrInput
	// A reference to the zone where the machine resides. Used to find the parent resource to bind the IAM policy to
	Location pulumi.StringPtrInput
	// The policy data generated by
	// a `organizations.getIAMPolicy` data source.
	PolicyData pulumi.StringPtrInput
	// The ID of the project in which the resource belongs.
	// If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
	Project pulumi.StringPtrInput
}

func (InstanceIamPolicyState) ElementType added in v4.1.0

func (InstanceIamPolicyState) ElementType() reflect.Type

type InstanceInput added in v4.4.0

type InstanceInput interface {
	pulumi.Input

	ToInstanceOutput() InstanceOutput
	ToInstanceOutputWithContext(ctx context.Context) InstanceOutput
}

type InstanceOutput added in v4.4.0

type InstanceOutput struct {
	*pulumi.OutputState
}

func (InstanceOutput) ElementType added in v4.4.0

func (InstanceOutput) ElementType() reflect.Type

func (InstanceOutput) ToInstanceOutput added in v4.4.0

func (o InstanceOutput) ToInstanceOutput() InstanceOutput

func (InstanceOutput) ToInstanceOutputWithContext added in v4.4.0

func (o InstanceOutput) ToInstanceOutputWithContext(ctx context.Context) InstanceOutput

type InstanceShieldedInstanceConfig added in v4.10.0

type InstanceShieldedInstanceConfig struct {
	// Defines whether the instance has integrity monitoring enabled. Enables monitoring and attestation of the
	// boot integrity of the instance. The attestation is performed against the integrity policy baseline.
	// This baseline is initially derived from the implicitly trusted boot image when the instance is created.
	// Enabled by default.
	EnableIntegrityMonitoring *bool `pulumi:"enableIntegrityMonitoring"`
	// Defines whether the instance has Secure Boot enabled. Secure Boot helps ensure that the system only runs
	// authentic software by verifying the digital signature of all boot components, and halting the boot process
	// if signature verification fails.
	// Disabled by default.
	EnableSecureBoot *bool `pulumi:"enableSecureBoot"`
	// Defines whether the instance has the vTPM enabled.
	// Enabled by default.
	EnableVtpm *bool `pulumi:"enableVtpm"`
}

type InstanceShieldedInstanceConfigArgs added in v4.10.0

type InstanceShieldedInstanceConfigArgs struct {
	// Defines whether the instance has integrity monitoring enabled. Enables monitoring and attestation of the
	// boot integrity of the instance. The attestation is performed against the integrity policy baseline.
	// This baseline is initially derived from the implicitly trusted boot image when the instance is created.
	// Enabled by default.
	EnableIntegrityMonitoring pulumi.BoolPtrInput `pulumi:"enableIntegrityMonitoring"`
	// Defines whether the instance has Secure Boot enabled. Secure Boot helps ensure that the system only runs
	// authentic software by verifying the digital signature of all boot components, and halting the boot process
	// if signature verification fails.
	// Disabled by default.
	EnableSecureBoot pulumi.BoolPtrInput `pulumi:"enableSecureBoot"`
	// Defines whether the instance has the vTPM enabled.
	// Enabled by default.
	EnableVtpm pulumi.BoolPtrInput `pulumi:"enableVtpm"`
}

func (InstanceShieldedInstanceConfigArgs) ElementType added in v4.10.0

func (InstanceShieldedInstanceConfigArgs) ToInstanceShieldedInstanceConfigOutput added in v4.10.0

func (i InstanceShieldedInstanceConfigArgs) ToInstanceShieldedInstanceConfigOutput() InstanceShieldedInstanceConfigOutput

func (InstanceShieldedInstanceConfigArgs) ToInstanceShieldedInstanceConfigOutputWithContext added in v4.10.0

func (i InstanceShieldedInstanceConfigArgs) ToInstanceShieldedInstanceConfigOutputWithContext(ctx context.Context) InstanceShieldedInstanceConfigOutput

func (InstanceShieldedInstanceConfigArgs) ToInstanceShieldedInstanceConfigPtrOutput added in v4.10.0

func (i InstanceShieldedInstanceConfigArgs) ToInstanceShieldedInstanceConfigPtrOutput() InstanceShieldedInstanceConfigPtrOutput

func (InstanceShieldedInstanceConfigArgs) ToInstanceShieldedInstanceConfigPtrOutputWithContext added in v4.10.0

func (i InstanceShieldedInstanceConfigArgs) ToInstanceShieldedInstanceConfigPtrOutputWithContext(ctx context.Context) InstanceShieldedInstanceConfigPtrOutput

type InstanceShieldedInstanceConfigInput added in v4.10.0

type InstanceShieldedInstanceConfigInput interface {
	pulumi.Input

	ToInstanceShieldedInstanceConfigOutput() InstanceShieldedInstanceConfigOutput
	ToInstanceShieldedInstanceConfigOutputWithContext(context.Context) InstanceShieldedInstanceConfigOutput
}

InstanceShieldedInstanceConfigInput is an input type that accepts InstanceShieldedInstanceConfigArgs and InstanceShieldedInstanceConfigOutput values. You can construct a concrete instance of `InstanceShieldedInstanceConfigInput` via:

InstanceShieldedInstanceConfigArgs{...}

type InstanceShieldedInstanceConfigOutput added in v4.10.0

type InstanceShieldedInstanceConfigOutput struct{ *pulumi.OutputState }

func (InstanceShieldedInstanceConfigOutput) ElementType added in v4.10.0

func (InstanceShieldedInstanceConfigOutput) EnableIntegrityMonitoring added in v4.10.0

func (o InstanceShieldedInstanceConfigOutput) EnableIntegrityMonitoring() pulumi.BoolPtrOutput

Defines whether the instance has integrity monitoring enabled. Enables monitoring and attestation of the boot integrity of the instance. The attestation is performed against the integrity policy baseline. This baseline is initially derived from the implicitly trusted boot image when the instance is created. Enabled by default.

func (InstanceShieldedInstanceConfigOutput) EnableSecureBoot added in v4.10.0

Defines whether the instance has Secure Boot enabled. Secure Boot helps ensure that the system only runs authentic software by verifying the digital signature of all boot components, and halting the boot process if signature verification fails. Disabled by default.

func (InstanceShieldedInstanceConfigOutput) EnableVtpm added in v4.10.0

Defines whether the instance has the vTPM enabled. Enabled by default.

func (InstanceShieldedInstanceConfigOutput) ToInstanceShieldedInstanceConfigOutput added in v4.10.0

func (o InstanceShieldedInstanceConfigOutput) ToInstanceShieldedInstanceConfigOutput() InstanceShieldedInstanceConfigOutput

func (InstanceShieldedInstanceConfigOutput) ToInstanceShieldedInstanceConfigOutputWithContext added in v4.10.0

func (o InstanceShieldedInstanceConfigOutput) ToInstanceShieldedInstanceConfigOutputWithContext(ctx context.Context) InstanceShieldedInstanceConfigOutput

func (InstanceShieldedInstanceConfigOutput) ToInstanceShieldedInstanceConfigPtrOutput added in v4.10.0

func (o InstanceShieldedInstanceConfigOutput) ToInstanceShieldedInstanceConfigPtrOutput() InstanceShieldedInstanceConfigPtrOutput

func (InstanceShieldedInstanceConfigOutput) ToInstanceShieldedInstanceConfigPtrOutputWithContext added in v4.10.0

func (o InstanceShieldedInstanceConfigOutput) ToInstanceShieldedInstanceConfigPtrOutputWithContext(ctx context.Context) InstanceShieldedInstanceConfigPtrOutput

type InstanceShieldedInstanceConfigPtrInput added in v4.10.0

type InstanceShieldedInstanceConfigPtrInput interface {
	pulumi.Input

	ToInstanceShieldedInstanceConfigPtrOutput() InstanceShieldedInstanceConfigPtrOutput
	ToInstanceShieldedInstanceConfigPtrOutputWithContext(context.Context) InstanceShieldedInstanceConfigPtrOutput
}

InstanceShieldedInstanceConfigPtrInput is an input type that accepts InstanceShieldedInstanceConfigArgs, InstanceShieldedInstanceConfigPtr and InstanceShieldedInstanceConfigPtrOutput values. You can construct a concrete instance of `InstanceShieldedInstanceConfigPtrInput` via:

        InstanceShieldedInstanceConfigArgs{...}

or:

        nil

type InstanceShieldedInstanceConfigPtrOutput added in v4.10.0

type InstanceShieldedInstanceConfigPtrOutput struct{ *pulumi.OutputState }

func (InstanceShieldedInstanceConfigPtrOutput) Elem added in v4.10.0

func (InstanceShieldedInstanceConfigPtrOutput) ElementType added in v4.10.0

func (InstanceShieldedInstanceConfigPtrOutput) EnableIntegrityMonitoring added in v4.10.0

func (o InstanceShieldedInstanceConfigPtrOutput) EnableIntegrityMonitoring() pulumi.BoolPtrOutput

Defines whether the instance has integrity monitoring enabled. Enables monitoring and attestation of the boot integrity of the instance. The attestation is performed against the integrity policy baseline. This baseline is initially derived from the implicitly trusted boot image when the instance is created. Enabled by default.

func (InstanceShieldedInstanceConfigPtrOutput) EnableSecureBoot added in v4.10.0

Defines whether the instance has Secure Boot enabled. Secure Boot helps ensure that the system only runs authentic software by verifying the digital signature of all boot components, and halting the boot process if signature verification fails. Disabled by default.

func (InstanceShieldedInstanceConfigPtrOutput) EnableVtpm added in v4.10.0

Defines whether the instance has the vTPM enabled. Enabled by default.

func (InstanceShieldedInstanceConfigPtrOutput) ToInstanceShieldedInstanceConfigPtrOutput added in v4.10.0

func (o InstanceShieldedInstanceConfigPtrOutput) ToInstanceShieldedInstanceConfigPtrOutput() InstanceShieldedInstanceConfigPtrOutput

func (InstanceShieldedInstanceConfigPtrOutput) ToInstanceShieldedInstanceConfigPtrOutputWithContext added in v4.10.0

func (o InstanceShieldedInstanceConfigPtrOutput) ToInstanceShieldedInstanceConfigPtrOutputWithContext(ctx context.Context) InstanceShieldedInstanceConfigPtrOutput

type InstanceState

type InstanceState struct {
	// The hardware accelerator used on this instance. If you use accelerators,
	// make sure that your configuration has enough vCPUs and memory to support the
	// machineType you have selected.
	// Structure is documented below.
	AcceleratorConfig InstanceAcceleratorConfigPtrInput
	// The size of the boot disk in GB attached to this instance,
	// up to a maximum of 64000 GB (64 TB). The minimum recommended value is 100 GB.
	// If not specified, this defaults to 100.
	BootDiskSizeGb pulumi.IntPtrInput
	// Possible disk types for notebook instances.
	// Possible values are `DISK_TYPE_UNSPECIFIED`, `PD_STANDARD`, `PD_SSD`, and `PD_BALANCED`.
	BootDiskType pulumi.StringPtrInput
	// Use a container image to start the notebook instance.
	// Structure is documented below.
	ContainerImage InstanceContainerImagePtrInput
	// Instance creation time
	CreateTime pulumi.StringPtrInput
	// Specify a custom Cloud Storage path where the GPU driver is stored.
	// If not specified, we'll automatically choose from official GPU drivers.
	CustomGpuDriverPath pulumi.StringPtrInput
	// The size of the data disk in GB attached to this instance,
	// up to a maximum of 64000 GB (64 TB).
	// You can choose the size of the data disk based on how big your notebooks and data are.
	// If not specified, this defaults to 100.
	DataDiskSizeGb pulumi.IntPtrInput
	// Possible disk types for notebook instances.
	// Possible values are `DISK_TYPE_UNSPECIFIED`, `PD_STANDARD`, `PD_SSD`, and `PD_BALANCED`.
	DataDiskType pulumi.StringPtrInput
	// Disk encryption method used on the boot and data disks, defaults to GMEK.
	// Possible values are `DISK_ENCRYPTION_UNSPECIFIED`, `GMEK`, and `CMEK`.
	DiskEncryption pulumi.StringPtrInput
	// Whether the end user authorizes Google Cloud to install GPU driver
	// on this instance. If this field is empty or set to false, the GPU driver
	// won't be installed. Only applicable to instances with GPUs.
	InstallGpuDriver pulumi.BoolPtrInput
	// The list of owners of this instance after creation.
	// Format: alias@example.com.
	// Currently supports one owner only.
	// If not specified, all of the service account users of
	// your VM instance's service account can use the instance.
	InstanceOwners pulumi.StringPtrInput
	// The KMS key used to encrypt the disks, only applicable if diskEncryption is CMEK.
	// Format: projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}
	KmsKey pulumi.StringPtrInput
	// Labels to apply to this instance. These can be later modified by the setLabels method.
	// An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
	Labels pulumi.StringMapInput
	// A reference to the zone where the machine resides.
	Location pulumi.StringPtrInput
	// A reference to a machine type which defines VM kind.
	MachineType pulumi.StringPtrInput
	// Custom metadata to apply to this instance.
	// An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
	Metadata pulumi.StringMapInput
	// The name specified for the Notebook instance.
	Name pulumi.StringPtrInput
	// The name of the VPC that this instance is in.
	// Format: projects/{project_id}/global/networks/{network_id}
	Network pulumi.StringPtrInput
	// The notebook instance will not register with the proxy..
	NoProxyAccess pulumi.BoolPtrInput
	// No public IP will be assigned to this instance.
	NoPublicIp pulumi.BoolPtrInput
	// If true, the data disk will not be auto deleted when deleting the instance.
	NoRemoveDataDisk pulumi.BoolPtrInput
	// Path to a Bash script that automatically runs after a
	// notebook instance fully boots up. The path must be a URL
	// or Cloud Storage path (gs://path-to-file/file-name).
	PostStartupScript pulumi.StringPtrInput
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project pulumi.StringPtrInput
	// The proxy endpoint that is used to access the Jupyter notebook.
	ProxyUri pulumi.StringPtrInput
	// The service account on this instance, giving access to other
	// Google Cloud services. You can use any service account within
	// the same project, but you must have the service account user
	// permission to use the instance. If not specified,
	// the Compute Engine default service account is used.
	ServiceAccount pulumi.StringPtrInput
	// Optional. The URIs of service account scopes to be included in Compute Engine instances.
	// If not specified, the following scopes are defined:
	// - https://www.googleapis.com/auth/cloud-platform
	// - https://www.googleapis.com/auth/userinfo.email
	ServiceAccountScopes pulumi.StringArrayInput
	// A set of Shielded Instance options. Check [Images using supported Shielded VM features]
	// Not all combinations are valid
	// Structure is documented below.
	ShieldedInstanceConfig InstanceShieldedInstanceConfigPtrInput
	// The state of this instance.
	State pulumi.StringPtrInput
	// The name of the subnet that this instance is in.
	// Format: projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}
	Subnet pulumi.StringPtrInput
	// The Compute Engine tags to add to runtime.
	Tags pulumi.StringArrayInput
	// Instance update time.
	UpdateTime pulumi.StringPtrInput
	// Use a Compute Engine VM image to start the notebook instance.
	// Structure is documented below.
	VmImage InstanceVmImagePtrInput
}

func (InstanceState) ElementType

func (InstanceState) ElementType() reflect.Type

type InstanceVmImage

type InstanceVmImage struct {
	// Use this VM image family to find the image; the newest image in this family will be used.
	ImageFamily *string `pulumi:"imageFamily"`
	// Use VM image name to find the image.
	ImageName *string `pulumi:"imageName"`
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project string `pulumi:"project"`
}

type InstanceVmImageArgs

type InstanceVmImageArgs struct {
	// Use this VM image family to find the image; the newest image in this family will be used.
	ImageFamily pulumi.StringPtrInput `pulumi:"imageFamily"`
	// Use VM image name to find the image.
	ImageName pulumi.StringPtrInput `pulumi:"imageName"`
	// The name of the Google Cloud project that this VM image belongs to.
	// Format: projects/{project_id}
	Project pulumi.StringInput `pulumi:"project"`
}

func (InstanceVmImageArgs) ElementType

func (InstanceVmImageArgs) ElementType() reflect.Type

func (InstanceVmImageArgs) ToInstanceVmImageOutput

func (i InstanceVmImageArgs) ToInstanceVmImageOutput() InstanceVmImageOutput

func (InstanceVmImageArgs) ToInstanceVmImageOutputWithContext

func (i InstanceVmImageArgs) ToInstanceVmImageOutputWithContext(ctx context.Context) InstanceVmImageOutput

func (InstanceVmImageArgs) ToInstanceVmImagePtrOutput

func (i InstanceVmImageArgs) ToInstanceVmImagePtrOutput() InstanceVmImagePtrOutput

func (InstanceVmImageArgs) ToInstanceVmImagePtrOutputWithContext

func (i InstanceVmImageArgs) ToInstanceVmImagePtrOutputWithContext(ctx context.Context) InstanceVmImagePtrOutput

type InstanceVmImageInput

type InstanceVmImageInput interface {
	pulumi.Input

	ToInstanceVmImageOutput() InstanceVmImageOutput
	ToInstanceVmImageOutputWithContext(context.Context) InstanceVmImageOutput
}

InstanceVmImageInput is an input type that accepts InstanceVmImageArgs and InstanceVmImageOutput values. You can construct a concrete instance of `InstanceVmImageInput` via:

InstanceVmImageArgs{...}

type InstanceVmImageOutput

type InstanceVmImageOutput struct{ *pulumi.OutputState }

func (InstanceVmImageOutput) ElementType

func (InstanceVmImageOutput) ElementType() reflect.Type

func (InstanceVmImageOutput) ImageFamily

Use this VM image family to find the image; the newest image in this family will be used.

func (InstanceVmImageOutput) ImageName

Use VM image name to find the image.

func (InstanceVmImageOutput) Project

The name of the Google Cloud project that this VM image belongs to. Format: projects/{project_id}

func (InstanceVmImageOutput) ToInstanceVmImageOutput

func (o InstanceVmImageOutput) ToInstanceVmImageOutput() InstanceVmImageOutput

func (InstanceVmImageOutput) ToInstanceVmImageOutputWithContext

func (o InstanceVmImageOutput) ToInstanceVmImageOutputWithContext(ctx context.Context) InstanceVmImageOutput

func (InstanceVmImageOutput) ToInstanceVmImagePtrOutput

func (o InstanceVmImageOutput) ToInstanceVmImagePtrOutput() InstanceVmImagePtrOutput

func (InstanceVmImageOutput) ToInstanceVmImagePtrOutputWithContext

func (o InstanceVmImageOutput) ToInstanceVmImagePtrOutputWithContext(ctx context.Context) InstanceVmImagePtrOutput

type InstanceVmImagePtrInput

type InstanceVmImagePtrInput interface {
	pulumi.Input

	ToInstanceVmImagePtrOutput() InstanceVmImagePtrOutput
	ToInstanceVmImagePtrOutputWithContext(context.Context) InstanceVmImagePtrOutput
}

InstanceVmImagePtrInput is an input type that accepts InstanceVmImageArgs, InstanceVmImagePtr and InstanceVmImagePtrOutput values. You can construct a concrete instance of `InstanceVmImagePtrInput` via:

        InstanceVmImageArgs{...}

or:

        nil

type InstanceVmImagePtrOutput

type InstanceVmImagePtrOutput struct{ *pulumi.OutputState }

func (InstanceVmImagePtrOutput) Elem

func (InstanceVmImagePtrOutput) ElementType

func (InstanceVmImagePtrOutput) ElementType() reflect.Type

func (InstanceVmImagePtrOutput) ImageFamily

Use this VM image family to find the image; the newest image in this family will be used.

func (InstanceVmImagePtrOutput) ImageName

Use VM image name to find the image.

func (InstanceVmImagePtrOutput) Project

The name of the Google Cloud project that this VM image belongs to. Format: projects/{project_id}

func (InstanceVmImagePtrOutput) ToInstanceVmImagePtrOutput

func (o InstanceVmImagePtrOutput) ToInstanceVmImagePtrOutput() InstanceVmImagePtrOutput

func (InstanceVmImagePtrOutput) ToInstanceVmImagePtrOutputWithContext

func (o InstanceVmImagePtrOutput) ToInstanceVmImagePtrOutputWithContext(ctx context.Context) InstanceVmImagePtrOutput

type Location

type Location struct {
	pulumi.CustomResourceState

	// Name of the Location resource.
	Name pulumi.StringOutput `pulumi:"name"`
	// The ID of the project in which the resource belongs.
	// If it is not provided, the provider project is used.
	Project pulumi.StringOutput `pulumi:"project"`
	// The URI of the created resource.
	SelfLink pulumi.StringOutput `pulumi:"selfLink"`
}

Represents a Location resource.

## Import

Location can be imported using any of these accepted formats

```sh

$ pulumi import gcp:notebooks/location:Location default projects/{{project}}/locations/{{name}}

```

```sh

$ pulumi import gcp:notebooks/location:Location default {{project}}/{{name}}

```

```sh

$ pulumi import gcp:notebooks/location:Location default {{name}}

```

func GetLocation

func GetLocation(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *LocationState, opts ...pulumi.ResourceOption) (*Location, error)

GetLocation gets an existing Location 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 NewLocation

func NewLocation(ctx *pulumi.Context,
	name string, args *LocationArgs, opts ...pulumi.ResourceOption) (*Location, error)

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

func (*Location) ElementType added in v4.4.0

func (*Location) ElementType() reflect.Type

func (*Location) ToLocationOutput added in v4.4.0

func (i *Location) ToLocationOutput() LocationOutput

func (*Location) ToLocationOutputWithContext added in v4.4.0

func (i *Location) ToLocationOutputWithContext(ctx context.Context) LocationOutput

type LocationArgs

type LocationArgs struct {
	// Name of the Location resource.
	Name pulumi.StringPtrInput
	// The ID of the project in which the resource belongs.
	// If it is not provided, the provider project is used.
	Project pulumi.StringPtrInput
}

The set of arguments for constructing a Location resource.

func (LocationArgs) ElementType

func (LocationArgs) ElementType() reflect.Type

type LocationInput added in v4.4.0

type LocationInput interface {
	pulumi.Input

	ToLocationOutput() LocationOutput
	ToLocationOutputWithContext(ctx context.Context) LocationOutput
}

type LocationOutput added in v4.4.0

type LocationOutput struct {
	*pulumi.OutputState
}

func (LocationOutput) ElementType added in v4.4.0

func (LocationOutput) ElementType() reflect.Type

func (LocationOutput) ToLocationOutput added in v4.4.0

func (o LocationOutput) ToLocationOutput() LocationOutput

func (LocationOutput) ToLocationOutputWithContext added in v4.4.0

func (o LocationOutput) ToLocationOutputWithContext(ctx context.Context) LocationOutput

type LocationState

type LocationState struct {
	// Name of the Location resource.
	Name pulumi.StringPtrInput
	// The ID of the project in which the resource belongs.
	// If it is not provided, the provider project is used.
	Project pulumi.StringPtrInput
	// The URI of the created resource.
	SelfLink pulumi.StringPtrInput
}

func (LocationState) ElementType

func (LocationState) ElementType() reflect.Type

Jump to

Keyboard shortcuts

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