Skip to content

Commit a9a2647

Browse files
feat: Automated regeneration of workstations v1 client (#18464)
Auto-created at 2024-03-10 10:25:30 +0000 using the toys pull request generator.
1 parent d3c76de commit a9a2647

File tree

5 files changed

+203
-15
lines changed

5 files changed

+203
-15
lines changed

api_names_out.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331016,6 +331016,9 @@
331016331016
"/workspaceevents:v1/workspaceevents.subscriptions.patch/validateOnly": validate_only
331017331017
"/workspaceevents:v1/workspaceevents.subscriptions.reactivate": reactivate_subscription
331018331018
"/workspaceevents:v1/workspaceevents.subscriptions.reactivate/name": name
331019+
"/workstations:v1/Accelerator": accelerator
331020+
"/workstations:v1/Accelerator/count": count
331021+
"/workstations:v1/Accelerator/type": type
331019331022
"/workstations:v1/AuditConfig": audit_config
331020331023
"/workstations:v1/AuditConfig/auditLogConfigs": audit_log_configs
331021331024
"/workstations:v1/AuditConfig/auditLogConfigs/audit_log_config": audit_log_config
@@ -331045,6 +331048,9 @@
331045331048
"/workstations:v1/CustomerEncryptionKey/kmsKeyServiceAccount": kms_key_service_account
331046331049
"/workstations:v1/DomainConfig": domain_config
331047331050
"/workstations:v1/DomainConfig/domain": domain
331051+
"/workstations:v1/EphemeralDirectory": ephemeral_directory
331052+
"/workstations:v1/EphemeralDirectory/gcePd": gce_pd
331053+
"/workstations:v1/EphemeralDirectory/mountPath": mount_path
331048331054
"/workstations:v1/Expr": expr
331049331055
"/workstations:v1/Expr/description": description
331050331056
"/workstations:v1/Expr/expression": expression
@@ -331053,9 +331059,12 @@
331053331059
"/workstations:v1/GceConfidentialInstanceConfig": gce_confidential_instance_config
331054331060
"/workstations:v1/GceConfidentialInstanceConfig/enableConfidentialCompute": enable_confidential_compute
331055331061
"/workstations:v1/GceInstance": gce_instance
331062+
"/workstations:v1/GceInstance/accelerators": accelerators
331063+
"/workstations:v1/GceInstance/accelerators/accelerator": accelerator
331056331064
"/workstations:v1/GceInstance/bootDiskSizeGb": boot_disk_size_gb
331057331065
"/workstations:v1/GceInstance/confidentialInstanceConfig": confidential_instance_config
331058331066
"/workstations:v1/GceInstance/disablePublicIpAddresses": disable_public_ip_addresses
331067+
"/workstations:v1/GceInstance/disableSsh": disable_ssh
331059331068
"/workstations:v1/GceInstance/enableNestedVirtualization": enable_nested_virtualization
331060331069
"/workstations:v1/GceInstance/machineType": machine_type
331061331070
"/workstations:v1/GceInstance/poolSize": pool_size
@@ -331066,6 +331075,11 @@
331066331075
"/workstations:v1/GceInstance/shieldedInstanceConfig": shielded_instance_config
331067331076
"/workstations:v1/GceInstance/tags": tags
331068331077
"/workstations:v1/GceInstance/tags/tag": tag
331078+
"/workstations:v1/GcePersistentDisk": gce_persistent_disk
331079+
"/workstations:v1/GcePersistentDisk/diskType": disk_type
331080+
"/workstations:v1/GcePersistentDisk/readOnly": read_only
331081+
"/workstations:v1/GcePersistentDisk/sourceImage": source_image
331082+
"/workstations:v1/GcePersistentDisk/sourceSnapshot": source_snapshot
331069331083
"/workstations:v1/GceRegionalPersistentDisk": gce_regional_persistent_disk
331070331084
"/workstations:v1/GceRegionalPersistentDisk/diskType": disk_type
331071331085
"/workstations:v1/GceRegionalPersistentDisk/fsType": fs_type
@@ -331240,6 +331254,8 @@
331240331254
"/workstations:v1/WorkstationConfig/displayName": display_name
331241331255
"/workstations:v1/WorkstationConfig/enableAuditAgent": enable_audit_agent
331242331256
"/workstations:v1/WorkstationConfig/encryptionKey": encryption_key
331257+
"/workstations:v1/WorkstationConfig/ephemeralDirectories": ephemeral_directories
331258+
"/workstations:v1/WorkstationConfig/ephemeralDirectories/ephemeral_directory": ephemeral_directory
331243331259
"/workstations:v1/WorkstationConfig/etag": etag
331244331260
"/workstations:v1/WorkstationConfig/host": host
331245331261
"/workstations:v1/WorkstationConfig/idleTimeout": idle_timeout

generated/google-apis-workstations_v1/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Release history for google-apis-workstations_v1
22

3+
### v0.9.0 (2024-03-10)
4+
5+
* Regenerated from discovery document revision 20240301
6+
37
### v0.8.0 (2024-02-23)
48

59
* Regenerated using generator version 0.14.0

generated/google-apis-workstations_v1/lib/google/apis/workstations_v1/classes.rb

Lines changed: 131 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,32 @@ module Google
2222
module Apis
2323
module WorkstationsV1
2424

25+
# An accelerator card attached to the instance.
26+
class Accelerator
27+
include Google::Apis::Core::Hashable
28+
29+
# Optional. Number of accelerator cards exposed to the instance.
30+
# Corresponds to the JSON property `count`
31+
# @return [Fixnum]
32+
attr_accessor :count
33+
34+
# Optional. Type of accelerator resource to attach to the instance, for example,
35+
# `"nvidia-tesla-p100"`.
36+
# Corresponds to the JSON property `type`
37+
# @return [String]
38+
attr_accessor :type
39+
40+
def initialize(**args)
41+
update!(**args)
42+
end
43+
44+
# Update properties of this object
45+
def update!(**args)
46+
@count = args[:count] if args.key?(:count)
47+
@type = args[:type] if args.key?(:type)
48+
end
49+
end
50+
2551
# Specifies the audit configuration for a service. The configuration determines
2652
# which permission types are logged, and what identities, if any, are exempted
2753
# from logging. An AuditConfig must have one or more AuditLogConfigs. If there
@@ -320,6 +346,32 @@ def update!(**args)
320346
end
321347
end
322348

349+
# An ephemeral directory which won't persist across workstation sessions. It is
350+
# freshly created on every workstation start operation.
351+
class EphemeralDirectory
352+
include Google::Apis::Core::Hashable
353+
354+
# An EphemeralDirectory is backed by a Compute Engine persistent disk.
355+
# Corresponds to the JSON property `gcePd`
356+
# @return [Google::Apis::WorkstationsV1::GcePersistentDisk]
357+
attr_accessor :gce_pd
358+
359+
# Required. Location of this directory in the running workstation.
360+
# Corresponds to the JSON property `mountPath`
361+
# @return [String]
362+
attr_accessor :mount_path
363+
364+
def initialize(**args)
365+
update!(**args)
366+
end
367+
368+
# Update properties of this object
369+
def update!(**args)
370+
@gce_pd = args[:gce_pd] if args.key?(:gce_pd)
371+
@mount_path = args[:mount_path] if args.key?(:mount_path)
372+
end
373+
end
374+
323375
# Represents a textual expression in the Common Expression Language (CEL) syntax.
324376
# CEL is a C-like expression language. The syntax and semantics of CEL are
325377
# documented at https://github.com/google/cel-spec. Example (Comparison): title:
@@ -398,6 +450,12 @@ def update!(**args)
398450
class GceInstance
399451
include Google::Apis::Core::Hashable
400452

453+
# Optional. A list of the type and count of accelerator cards attached to the
454+
# instance.
455+
# Corresponds to the JSON property `accelerators`
456+
# @return [Array<Google::Apis::WorkstationsV1::Accelerator>]
457+
attr_accessor :accelerators
458+
401459
# Optional. The size of the boot disk for the VM in gigabytes (GB). The minimum
402460
# boot disk size is `30` GB. Defaults to `50` GB.
403461
# Corresponds to the JSON property `bootDiskSizeGb`
@@ -420,8 +478,14 @@ class GceInstance
420478
attr_accessor :disable_public_ip_addresses
421479
alias_method :disable_public_ip_addresses?, :disable_public_ip_addresses
422480

481+
# Optional. Whether to disable SSH access to the VM.
482+
# Corresponds to the JSON property `disableSsh`
483+
# @return [Boolean]
484+
attr_accessor :disable_ssh
485+
alias_method :disable_ssh?, :disable_ssh
486+
423487
# Optional. Whether to enable nested virtualization on Cloud Workstations VMs
424-
# created under this workstation configuration. Nested virtualization lets you
488+
# created using this workstation configuration. Nested virtualization lets you
425489
# run virtual machine (VM) instances inside your workstation. Before enabling
426490
# nested virtualization, consider the following important considerations. Cloud
427491
# Workstations instances are subject to the [same restrictions as Compute Engine
@@ -514,9 +578,11 @@ def initialize(**args)
514578

515579
# Update properties of this object
516580
def update!(**args)
581+
@accelerators = args[:accelerators] if args.key?(:accelerators)
517582
@boot_disk_size_gb = args[:boot_disk_size_gb] if args.key?(:boot_disk_size_gb)
518583
@confidential_instance_config = args[:confidential_instance_config] if args.key?(:confidential_instance_config)
519584
@disable_public_ip_addresses = args[:disable_public_ip_addresses] if args.key?(:disable_public_ip_addresses)
585+
@disable_ssh = args[:disable_ssh] if args.key?(:disable_ssh)
520586
@enable_nested_virtualization = args[:enable_nested_virtualization] if args.key?(:enable_nested_virtualization)
521587
@machine_type = args[:machine_type] if args.key?(:machine_type)
522588
@pool_size = args[:pool_size] if args.key?(:pool_size)
@@ -528,10 +594,55 @@ def update!(**args)
528594
end
529595
end
530596

531-
# A PersistentDirectory backed by a Compute Engine regional persistent disk. The
532-
# persistent_directories field is repeated, but it may contain only one entry.
533-
# It creates a [persistent disk](https://cloud.google.com/compute/docs/disks/
534-
# persistent-disks) that mounts to the workstation VM at `/home` when the
597+
# An EphemeralDirectory is backed by a Compute Engine persistent disk.
598+
class GcePersistentDisk
599+
include Google::Apis::Core::Hashable
600+
601+
# Optional. Type of the disk to use. Defaults to `"pd-standard"`.
602+
# Corresponds to the JSON property `diskType`
603+
# @return [String]
604+
attr_accessor :disk_type
605+
606+
# Optional. Whether the disk is read only. If true, the disk may be shared by
607+
# multiple VMs and source_snapshot must be set.
608+
# Corresponds to the JSON property `readOnly`
609+
# @return [Boolean]
610+
attr_accessor :read_only
611+
alias_method :read_only?, :read_only
612+
613+
# Optional. Name of the disk image to use as the source for the disk. Must be
614+
# empty if source_snapshot is set. Updating source_image will update content in
615+
# the ephemeral directory after the workstation is restarted. This field is
616+
# mutable.
617+
# Corresponds to the JSON property `sourceImage`
618+
# @return [String]
619+
attr_accessor :source_image
620+
621+
# Optional. Name of the snapshot to use as the source for the disk. Must be
622+
# empty if source_image is set. Must be empty if read_only is false. Updating
623+
# source_snapshot will update content in the ephemeral directory after the
624+
# workstation is restarted. This field is mutable.
625+
# Corresponds to the JSON property `sourceSnapshot`
626+
# @return [String]
627+
attr_accessor :source_snapshot
628+
629+
def initialize(**args)
630+
update!(**args)
631+
end
632+
633+
# Update properties of this object
634+
def update!(**args)
635+
@disk_type = args[:disk_type] if args.key?(:disk_type)
636+
@read_only = args[:read_only] if args.key?(:read_only)
637+
@source_image = args[:source_image] if args.key?(:source_image)
638+
@source_snapshot = args[:source_snapshot] if args.key?(:source_snapshot)
639+
end
640+
end
641+
642+
# A Persistent Directory backed by a Compute Engine regional persistent disk.
643+
# The persistent_directories field is repeated, but it may contain only one
644+
# entry. It creates a [persistent disk](https://cloud.google.com/compute/docs/
645+
# disks/persistent-disks) that mounts to the workstation VM at `/home` when the
535646
# session starts and detaches when the session ends. If this field is empty,
536647
# workstations created with this configuration do not have a persistent home
537648
# directory.
@@ -1090,10 +1201,10 @@ def update!(**args)
10901201
class PersistentDirectory
10911202
include Google::Apis::Core::Hashable
10921203

1093-
# A PersistentDirectory backed by a Compute Engine regional persistent disk. The
1094-
# persistent_directories field is repeated, but it may contain only one entry.
1095-
# It creates a [persistent disk](https://cloud.google.com/compute/docs/disks/
1096-
# persistent-disks) that mounts to the workstation VM at `/home` when the
1204+
# A Persistent Directory backed by a Compute Engine regional persistent disk.
1205+
# The persistent_directories field is repeated, but it may contain only one
1206+
# entry. It creates a [persistent disk](https://cloud.google.com/compute/docs/
1207+
# disks/persistent-disks) that mounts to the workstation VM at `/home` when the
10971208
# session starts and detaches when the session ends. If this field is empty,
10981209
# workstations created with this configuration do not have a persistent home
10991210
# directory.
@@ -1764,10 +1875,10 @@ class WorkstationConfig
17641875
attr_accessor :delete_time
17651876

17661877
# Optional. Disables support for plain TCP connections in the workstation. By
1767-
# default the service supports TCP connections via a websocket relay. Setting
1768-
# this option to true disables that relay, which prevents the usage of services
1769-
# that require plain tcp connections, such as ssh. When enabled, all
1770-
# communication must occur over https or wss.
1878+
# default the service supports TCP connections through a websocket relay.
1879+
# Setting this option to true disables that relay, which prevents the usage of
1880+
# services that require plain TCP connections, such as SSH. When enabled, all
1881+
# communication must occur over HTTPS or WSS.
17711882
# Corresponds to the JSON property `disableTcpConnections`
17721883
# @return [Boolean]
17731884
attr_accessor :disable_tcp_connections
@@ -1797,6 +1908,12 @@ class WorkstationConfig
17971908
# @return [Google::Apis::WorkstationsV1::CustomerEncryptionKey]
17981909
attr_accessor :encryption_key
17991910

1911+
# Optional. Ephemeral directories which won't persist across workstation
1912+
# sessions.
1913+
# Corresponds to the JSON property `ephemeralDirectories`
1914+
# @return [Array<Google::Apis::WorkstationsV1::EphemeralDirectory>]
1915+
attr_accessor :ephemeral_directories
1916+
18001917
# Optional. Checksum computed by the server. May be sent on update and delete
18011918
# requests to make sure that the client has an up-to-date value before
18021919
# proceeding.
@@ -1904,6 +2021,7 @@ def update!(**args)
19042021
@display_name = args[:display_name] if args.key?(:display_name)
19052022
@enable_audit_agent = args[:enable_audit_agent] if args.key?(:enable_audit_agent)
19062023
@encryption_key = args[:encryption_key] if args.key?(:encryption_key)
2024+
@ephemeral_directories = args[:ephemeral_directories] if args.key?(:ephemeral_directories)
19072025
@etag = args[:etag] if args.key?(:etag)
19082026
@host = args[:host] if args.key?(:host)
19092027
@idle_timeout = args[:idle_timeout] if args.key?(:idle_timeout)

generated/google-apis-workstations_v1/lib/google/apis/workstations_v1/gem_version.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ module Google
1616
module Apis
1717
module WorkstationsV1
1818
# Version of the google-apis-workstations_v1 gem
19-
GEM_VERSION = "0.8.0"
19+
GEM_VERSION = "0.9.0"
2020

2121
# Version of the code generator used to generate this client
2222
GENERATOR_VERSION = "0.14.0"
2323

2424
# Revision of the discovery document this client was generated from
25-
REVISION = "20240130"
25+
REVISION = "20240301"
2626
end
2727
end
2828
end

0 commit comments

Comments
 (0)