Types for Google Cloud Notebooks v2 API¶
- class google.cloud.notebooks_v2.types.AcceleratorConfig(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
An accelerator configuration for a VM instance Definition of a hardware accelerator. Note that there is no check on
type
andcore_count
combinations. TPUs are not supported. See GPUs on Compute Engine to find a valid combination.- type_¶
Optional. Type of this accelerator.
- class AcceleratorType(value)[source]¶
Bases:
proto.enums.Enum
Definition of the types of hardware accelerators that can be used on this instance.
- Values:
- ACCELERATOR_TYPE_UNSPECIFIED (0):
Accelerator type is not specified.
- NVIDIA_TESLA_P100 (2):
Accelerator type is Nvidia Tesla P100.
- NVIDIA_TESLA_V100 (3):
Accelerator type is Nvidia Tesla V100.
- NVIDIA_TESLA_P4 (4):
Accelerator type is Nvidia Tesla P4.
- NVIDIA_TESLA_T4 (5):
Accelerator type is Nvidia Tesla T4.
- NVIDIA_TESLA_A100 (11):
Accelerator type is Nvidia Tesla A100 - 40GB.
- NVIDIA_A100_80GB (12):
Accelerator type is Nvidia Tesla A100 - 80GB.
- NVIDIA_L4 (13):
Accelerator type is Nvidia Tesla L4.
- NVIDIA_TESLA_T4_VWS (8):
Accelerator type is NVIDIA Tesla T4 Virtual Workstations.
- NVIDIA_TESLA_P100_VWS (9):
Accelerator type is NVIDIA Tesla P100 Virtual Workstations.
- NVIDIA_TESLA_P4_VWS (10):
Accelerator type is NVIDIA Tesla P4 Virtual Workstations.
- class google.cloud.notebooks_v2.types.BootDisk(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
The definition of a boot disk.
- disk_size_gb¶
Optional. The size of the boot disk in GB attached to this instance, up to a maximum of 64000 GB (64 TB). If not specified, this defaults to the recommended value of 150GB.
- Type
- disk_type¶
Optional. Indicates the type of the disk.
- disk_encryption¶
Optional. Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
- class google.cloud.notebooks_v2.types.CheckInstanceUpgradabilityRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for checking if a notebook instance is upgradeable.
- class google.cloud.notebooks_v2.types.CheckInstanceUpgradabilityResponse(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Response for checking if a notebook instance is upgradeable.
- upgrade_version¶
The version this instance will be upgraded to if calling the upgrade endpoint. This field will only be populated if field upgradeable is true.
- Type
- class google.cloud.notebooks_v2.types.ContainerImage(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Definition of a container image for starting a notebook instance with the environment installed in a container.
- repository¶
Required. The path to the container image repository. For example:
gcr.io/{project_id}/{image_name}
- Type
- class google.cloud.notebooks_v2.types.CreateInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for creating a notebook instance.
- instance¶
Required. The instance to be created.
- class google.cloud.notebooks_v2.types.DataDisk(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
An instance-attached disk resource.
- disk_size_gb¶
Optional. The size of the disk in GB attached to this VM instance, up to a maximum of 64000 GB (64 TB). If not specified, this defaults to 100.
- Type
- disk_type¶
Optional. Input only. Indicates the type of the disk.
- disk_encryption¶
Optional. Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
- class google.cloud.notebooks_v2.types.DeleteInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for deleting a notebook instance.
- class google.cloud.notebooks_v2.types.DiagnoseInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for creating a notebook instance diagnostic file.
- diagnostic_config¶
Required. Defines flags that are used to run the diagnostic tool
- class google.cloud.notebooks_v2.types.DiagnosticConfig(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Defines flags that are used to run the diagnostic tool
- gcs_bucket¶
Required. User Cloud Storage bucket location (REQUIRED). Must be formatted with path prefix (
gs://$GCS_BUCKET
).Permissions: User Managed Notebooks:
storage.buckets.writer: Must be given to the project’s service account attached to VM. Google Managed Notebooks:
storage.buckets.writer: Must be given to the project’s service account or user credentials attached to VM depending on authentication mode.
Cloud Storage bucket Log file will be written to
gs://$GCS_BUCKET/$RELATIVE_PATH/$VM_DATE_$TIME.tar.gz
- Type
- relative_path¶
Optional. Defines the relative storage path in the Cloud Storage bucket where the diagnostic logs will be written: Default path will be the root directory of the Cloud Storage bucket (
gs://$GCS_BUCKET/$DATE_$TIME.tar.gz
) Example of full path where Log file will be written:gs://$GCS_BUCKET/$RELATIVE_PATH/
- Type
- enable_packet_capture_flag¶
Optional. Enables flag to capture packets from the instance for 30 seconds
- Type
- class google.cloud.notebooks_v2.types.DiskEncryption(value)[source]¶
Bases:
proto.enums.Enum
Definition of the disk encryption options.
- Values:
- DISK_ENCRYPTION_UNSPECIFIED (0):
Disk encryption is not specified.
- GMEK (1):
Use Google managed encryption keys to encrypt the boot disk.
- CMEK (2):
Use customer managed encryption keys to encrypt the boot disk.
- class google.cloud.notebooks_v2.types.DiskType(value)[source]¶
Bases:
proto.enums.Enum
Possible disk types.
- Values:
- DISK_TYPE_UNSPECIFIED (0):
Disk type not set.
- PD_STANDARD (1):
Standard persistent disk type.
- PD_SSD (2):
SSD persistent disk type.
- PD_BALANCED (3):
Balanced persistent disk type.
- PD_EXTREME (4):
Extreme persistent disk type.
- class google.cloud.notebooks_v2.types.Event(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
The definition of an Event for a managed / semi-managed notebook instance.
- report_time¶
Optional. Event report time.
- type_¶
Optional. Event type.
- details¶
Optional. Event details. This field is used to pass event information.
- class DetailsEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)¶
Bases:
proto.message.Message
- class EventType(value)[source]¶
Bases:
proto.enums.Enum
The definition of the event types.
- Values:
- EVENT_TYPE_UNSPECIFIED (0):
Event is not specified.
- IDLE (1):
The instance / runtime is idle
- HEARTBEAT (2):
The instance / runtime is available. This event indicates that instance / runtime underlying compute is operational.
- HEALTH (3):
The instance / runtime health is available. This event indicates that instance / runtime health information.
- MAINTENANCE (4):
The instance / runtime is available. This event allows instance / runtime to send Host maintenance information to Control Plane. https://cloud.google.com/compute/docs/gpus/gpu-host-maintenance
- METADATA_CHANGE (5):
The instance / runtime is available. This event indicates that the instance had metadata that needs to be modified.
- class google.cloud.notebooks_v2.types.GPUDriverConfig(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
A GPU driver configuration
- enable_gpu_driver¶
Optional. Whether the end user authorizes Google Cloud to install GPU driver on this VM instance. If this field is empty or set to false, the GPU driver won’t be installed. Only applicable to instances with GPUs.
- Type
- class google.cloud.notebooks_v2.types.GceSetup(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
The definition of how to configure a VM instance outside of Resources and Identity.
This message has oneof fields (mutually exclusive fields). For each oneof, at most one member field can be set at the same time. Setting any member of the oneof automatically clears all other members.
- machine_type¶
Optional. The machine type of the VM instance. https://cloud.google.com/compute/docs/machine-resource
- Type
- accelerator_configs¶
Optional. The hardware accelerators used on this instance. If you use accelerators, make sure that your configuration has enough vCPUs and memory to support the ``machine_type` you have selected <https://cloud.google.com/compute/docs/gpus/#gpus-list>`__. Currently supports only one accelerator configuration.
- Type
MutableSequence[google.cloud.notebooks_v2.types.AcceleratorConfig]
- service_accounts¶
Optional. The service account that serves as an identity for the VM instance. Currently supports only one service account.
- Type
MutableSequence[google.cloud.notebooks_v2.types.ServiceAccount]
- vm_image¶
Optional. Use a Compute Engine VM image to start the notebook instance.
This field is a member of oneof
image
.
- container_image¶
Optional. Use a container image to start the notebook instance.
This field is a member of oneof
image
.
- boot_disk¶
Optional. The boot disk for the VM.
- data_disks¶
Optional. Data disks attached to the VM instance. Currently supports only one data disk.
- Type
MutableSequence[google.cloud.notebooks_v2.types.DataDisk]
- shielded_instance_config¶
Optional. Shielded VM configuration. Images using supported Shielded VM features.
- network_interfaces¶
Optional. The network interfaces for the VM. Supports only one interface.
- Type
MutableSequence[google.cloud.notebooks_v2.types.NetworkInterface]
- disable_public_ip¶
Optional. If true, no external IP will be assigned to this VM instance.
- Type
- tags¶
Optional. The Compute Engine tags to add to runtime (see Tagging instances).
- Type
MutableSequence[str]
- enable_ip_forwarding¶
Optional. Flag to enable ip forwarding or not, default false/off. https://cloud.google.com/vpc/docs/using-routes#canipforward
- Type
- gpu_driver_config¶
Optional. Configuration for GPU drivers.
- class MetadataEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)¶
Bases:
proto.message.Message
- class google.cloud.notebooks_v2.types.GetInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for getting a notebook instance.
- class google.cloud.notebooks_v2.types.HealthState(value)[source]¶
Bases:
proto.enums.Enum
The instance health state.
- Values:
- HEALTH_STATE_UNSPECIFIED (0):
The instance substate is unknown.
- HEALTHY (1):
The instance is known to be in an healthy state (for example, critical daemons are running) Applies to ACTIVE state.
- UNHEALTHY (2):
The instance is known to be in an unhealthy state (for example, critical daemons are not running) Applies to ACTIVE state.
- AGENT_NOT_INSTALLED (3):
The instance has not installed health monitoring agent. Applies to ACTIVE state.
- AGENT_NOT_RUNNING (4):
The instance health monitoring agent is not running. Applies to ACTIVE state.
- class google.cloud.notebooks_v2.types.Instance(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
The definition of a notebook instance.
- name¶
Output only. The name of this notebook instance. Format:
projects/{project_id}/locations/{location}/instances/{instance_id}
- Type
- gce_setup¶
Optional. Compute Engine setup for the notebook. Uses notebook-defined fields.
This field is a member of oneof
infrastructure
.
- instance_owners¶
Optional. Input only. The owner 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.
- Type
MutableSequence[str]
- state¶
Output only. The state of this instance.
- upgrade_history¶
Output only. The upgrade history of this instance.
- Type
MutableSequence[google.cloud.notebooks_v2.types.UpgradeHistoryEntry]
- health_state¶
Output only. Instance health_state.
- health_info¶
Output only. Additional information about instance health. Example:
healthInfo": { "docker_proxy_agent_status": "1", "docker_status": "1", "jupyterlab_api_status": "-1", "jupyterlab_status": "-1", "updated": "2020-10-18 09:40:03.573409" }
- create_time¶
Output only. Instance creation time.
- update_time¶
Output only. Instance update time.
- disable_proxy_access¶
Optional. If true, the notebook instance will not register with the proxy.
- Type
- labels¶
Optional. Labels to apply to this instance. These can be later modified by the UpdateInstance method.
- class HealthInfoEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)¶
Bases:
proto.message.Message
- class LabelsEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)¶
Bases:
proto.message.Message
- class google.cloud.notebooks_v2.types.ListInstancesRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for listing notebook instances.
- page_token¶
Optional. A previous returned page token that can be used to continue listing from the last result.
- Type
- order_by¶
Optional. Sort results. Supported values are “name”, “name desc” or “” (unsorted).
- Type
- class google.cloud.notebooks_v2.types.ListInstancesResponse(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Response for listing notebook instances.
- instances¶
A list of returned instances.
- Type
MutableSequence[google.cloud.notebooks_v2.types.Instance]
- next_page_token¶
Page token that can be used to continue listing from the last result in the next list call.
- Type
- class google.cloud.notebooks_v2.types.NetworkInterface(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
The definition of a network interface resource attached to a VM.
- network¶
Optional. The name of the VPC that this VM instance is in. Format:
projects/{project_id}/global/networks/{network_id}
- Type
- subnet¶
Optional. The name of the subnet that this VM instance is in. Format:
projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}
- Type
- nic_type¶
Optional. The type of vNIC to be used on this interface. This may be gVNIC or VirtioNet.
- class NicType(value)[source]¶
Bases:
proto.enums.Enum
The type of vNIC driver. Default should be NIC_TYPE_UNSPECIFIED.
- Values:
- NIC_TYPE_UNSPECIFIED (0):
No type specified.
- VIRTIO_NET (1):
VIRTIO
- GVNIC (2):
GVNIC
- class google.cloud.notebooks_v2.types.OperationMetadata(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Represents the metadata of the long-running operation.
- create_time¶
The time the operation was created.
- end_time¶
The time the operation finished running.
- requested_cancellation¶
Identifies whether the user has requested cancellation of the operation. Operations that have successfully been cancelled have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to
Code.CANCELLED
.- Type
- class google.cloud.notebooks_v2.types.ResetInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for resetting a notebook instance
- class google.cloud.notebooks_v2.types.RollbackInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for rollbacking a notebook instance
- target_snapshot¶
Required. The snapshot for rollback. Example: “projects/test-project/global/snapshots/krwlzipynril”.
- Type
- class google.cloud.notebooks_v2.types.ServiceAccount(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
A service account that acts as an identity.
- scopes¶
Output only. The list of scopes to be made available for this service account. Set by the CLH to https://www.googleapis.com/auth/cloud-platform
- Type
MutableSequence[str]
- class google.cloud.notebooks_v2.types.ShieldedInstanceConfig(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
A set of Shielded Instance options. See Images using supported Shielded VM features. Not all combinations are valid.
- enable_secure_boot¶
Optional. Defines whether the VM 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.
- Type
- enable_vtpm¶
Optional. Defines whether the VM instance has the vTPM enabled. Enabled by default.
- Type
- enable_integrity_monitoring¶
Optional. Defines whether the VM instance has integrity monitoring enabled. Enables monitoring and attestation of the boot integrity of the VM instance. The attestation is performed against the integrity policy baseline. This baseline is initially derived from the implicitly trusted boot image when the VM instance is created. Enabled by default.
- Type
- class google.cloud.notebooks_v2.types.StartInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for starting a notebook instance
- class google.cloud.notebooks_v2.types.State(value)[source]¶
Bases:
proto.enums.Enum
The definition of the states of this instance.
- Values:
- STATE_UNSPECIFIED (0):
State is not specified.
- STARTING (1):
The control logic is starting the instance.
- PROVISIONING (2):
The control logic is installing required frameworks and registering the instance with notebook proxy
- ACTIVE (3):
The instance is running.
- STOPPING (4):
The control logic is stopping the instance.
- STOPPED (5):
The instance is stopped.
- DELETED (6):
The instance is deleted.
- UPGRADING (7):
The instance is upgrading.
- INITIALIZING (8):
The instance is being created.
- SUSPENDING (9):
The instance is suspending.
- SUSPENDED (10):
The instance is suspended.
- class google.cloud.notebooks_v2.types.StopInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for stopping a notebook instance
- class google.cloud.notebooks_v2.types.UpdateInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for updating a notebook instance.
- instance¶
Required. A representation of an instance.
- update_mask¶
Required. Mask used to update an instance
- class google.cloud.notebooks_v2.types.UpgradeHistoryEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
The entry of VM image upgrade history.
- snapshot¶
Optional. The snapshot of the boot disk of this notebook instance before upgrade.
- Type
- state¶
Output only. The state of this instance upgrade history entry.
- create_time¶
Immutable. The time that this instance upgrade history entry is created.
- action¶
Optional. Action. Rolloback or Upgrade.
- class Action(value)[source]¶
Bases:
proto.enums.Enum
The definition of operations of this upgrade history entry.
- Values:
- ACTION_UNSPECIFIED (0):
Operation is not specified.
- UPGRADE (1):
Upgrade.
- ROLLBACK (2):
Rollback.
- class State(value)[source]¶
Bases:
proto.enums.Enum
The definition of the states of this upgrade history entry.
- Values:
- STATE_UNSPECIFIED (0):
State is not specified.
- STARTED (1):
The instance upgrade is started.
- SUCCEEDED (2):
The instance upgrade is succeeded.
- FAILED (3):
The instance upgrade is failed.
- class google.cloud.notebooks_v2.types.UpgradeInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Request for upgrading a notebook instance
- class google.cloud.notebooks_v2.types.VmImage(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]¶
Bases:
proto.message.Message
Definition of a custom Compute Engine virtual machine image for starting a notebook instance with the environment installed directly on the VM.
This message has oneof fields (mutually exclusive fields). For each oneof, at most one member field can be set at the same time. Setting any member of the oneof automatically clears all other members.
- project¶
Required. The name of the Google Cloud project that this VM image belongs to. Format:
{project_id}
- Type