Skip to content

Commit

Permalink
feat: add DNS address, Kubernetes primary VLAN ID, and provisioning s…
Browse files Browse the repository at this point in the history
…tate to the Zone resource

feat: add MAC address-associated IP address to the Hardware resource
docs: change state_signal field in SignalZoneState method request as optional
feat: add provisioning_state_signal field in SignalZoneState method request

PiperOrigin-RevId: 695813387
  • Loading branch information
Google APIs authored and copybara-github committed Nov 12, 2024
1 parent b800515 commit dee637f
Show file tree
Hide file tree
Showing 3 changed files with 63 additions and 2 deletions.
3 changes: 3 additions & 0 deletions google/cloud/gdchardwaremanagement/v1alpha/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,8 @@ py_gapic_library(
rest_numeric_enums = True,
service_yaml = "gdchardwaremanagement_v1alpha.yaml",
transport = "grpc+rest",
deps = [
],
)

py_test(
Expand Down Expand Up @@ -349,6 +351,7 @@ load(

csharp_proto_library(
name = "gdchardwaremanagement_csharp_proto",
extra_opts = [],
deps = [":gdchardwaremanagement_proto"],
)

Expand Down
40 changes: 40 additions & 0 deletions google/cloud/gdchardwaremanagement/v1alpha/resources.proto
Original file line number Diff line number Diff line change
Expand Up @@ -379,6 +379,13 @@ message Hardware {

// Output only. Address type for this MAC address.
AddressType type = 2 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Static IP address (if used) that is associated with the MAC
// address. Only applicable for VIRTUAL MAC address type.
string ipv4_address = 3 [
(google.api.field_info).format = IPV4,
(google.api.field_behavior) = OUTPUT_ONLY
];
}

// Information about individual disks on a machine.
Expand Down Expand Up @@ -704,6 +711,21 @@ message Zone {
CANCELLED = 4;
}

// Valid provisioning states for configurations like MAC addresses.
enum ProvisioningState {
// Provisioning state is unspecified.
PROVISIONING_STATE_UNSPECIFIED = 0;

// Provisioning is required. Set by Google.
PROVISIONING_REQUIRED = 1;

// Provisioning is in progress. Set by customer.
PROVISIONING_IN_PROGRESS = 2;

// Provisioning is complete. Set by customer.
PROVISIONING_COMPLETE = 3;
}

// Identifier. Name of this zone.
// Format: `projects/{project}/locations/{location}/zones/{zone}`
string name = 1 [(google.api.field_behavior) = IDENTIFIER];
Expand Down Expand Up @@ -744,6 +766,10 @@ message Zone {
// Output only. Subscription configurations for this zone.
repeated SubscriptionConfig subscription_configs = 13
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Provisioning state for configurations like MAC addresses.
ProvisioningState provisioning_state = 14
[(google.api.field_behavior) = OUTPUT_ONLY];
}

// Contact information of the customer organization.
Expand Down Expand Up @@ -979,6 +1005,20 @@ message ZoneNetworkConfig {
// If unspecified, the kubernetes subnet will be the same as the management
// subnet.
Subnet kubernetes_ipv4_subnet = 5 [(google.api.field_behavior) = OPTIONAL];

// Optional. DNS nameservers.
// The GDC Infrastructure will resolve DNS queries via these IPs.
// If unspecified, Google DNS is used.
repeated string dns_ipv4_addresses = 6 [
(google.api.field_info).format = IPV4,
(google.api.field_behavior) = OPTIONAL
];

// Optional. Kubernetes VLAN ID.
// By default, the kubernetes node, including the primary kubernetes network,
// are in the same VLAN as the machine management network.
// For network segmentation purposes, these can optionally be separated.
int32 kubernetes_primary_vlan_id = 7 [(google.api.field_behavior) = OPTIONAL];
}

// Represents a subnet.
Expand Down
22 changes: 20 additions & 2 deletions google/cloud/gdchardwaremanagement/v1alpha/service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -1290,6 +1290,18 @@ message SignalZoneStateRequest {
FACTORY_TURNUP_CHECKS_FAILED = 2;
}

// Valid provisioning state signals for a zone.
enum ProvisioningStateSignal {
// Provisioning state signal is unspecified.
PROVISIONING_STATE_SIGNAL_UNSPECIFIED = 0;

// Provisioning is in progress.
PROVISIONING_IN_PROGRESS = 1;

// Provisioning is complete.
PROVISIONING_COMPLETE = 2;
}

// Required. The name of the zone.
// Format: `projects/{project}/locations/{location}/zones/{zone}`
string name = 1 [
Expand All @@ -1306,8 +1318,14 @@ message SignalZoneStateRequest {
(google.api.field_behavior) = OPTIONAL
];

// Required. The state signal to send for this zone.
StateSignal state_signal = 3 [(google.api.field_behavior) = REQUIRED];
// Optional. The state signal to send for this zone. Either state_signal or
// provisioning_state_signal must be set, but not both.
StateSignal state_signal = 3 [(google.api.field_behavior) = OPTIONAL];

// Optional. The provisioning state signal to send for this zone. Either
// state_signal or provisioning_state_signal must be set, but not both.
ProvisioningStateSignal provisioning_state_signal = 4
[(google.api.field_behavior) = OPTIONAL];
}

// Represents the metadata of a long-running operation.
Expand Down

0 comments on commit dee637f

Please sign in to comment.