Skip to content

Commit 48d30c4

Browse files
Google APIscopybara-github
authored andcommitted
feat: Add PrivateServiceConnect option to WorkerPool
PiperOrigin-RevId: 690046730
1 parent 0b8fa52 commit 48d30c4

1 file changed

Lines changed: 47 additions & 0 deletions

File tree

google/devtools/cloudbuild/v1/cloudbuild.proto

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,10 @@ option (google.api.resource_definition) = {
6767
type: "pubsub.googleapis.com/Topic"
6868
pattern: "projects/{project}/topics/{topic}"
6969
};
70+
option (google.api.resource_definition) = {
71+
type: "compute.googleapis.com/NetworkAttachment"
72+
pattern: "projects/{project}/regions/{region}/networkAttachments/{networkattachment}"
73+
};
7074
option (google.api.resource_definition) = {
7175
type: "cloudbuild.googleapis.com/Repository"
7276
pattern: "projects/{project}/locations/{location}/connections/{connection}/repositories/{repository}"
@@ -2583,11 +2587,54 @@ message PrivatePoolV1Config {
25832587
[(google.api.field_behavior) = IMMUTABLE];
25842588
}
25852589

2590+
// Defines the Private Service Connect network configuration for the pool.
2591+
message PrivateServiceConnect {
2592+
// Required. Immutable. The network attachment that the worker network
2593+
// interface is peered to. Must be in the format
2594+
// `projects/{project}/regions/{region}/networkAttachments/{networkAttachment}`.
2595+
// The region of network attachment must be the same as the worker pool.
2596+
// See [Network
2597+
// Attachments](https://cloud.google.com/vpc/docs/about-network-attachments)
2598+
string network_attachment = 1 [
2599+
(google.api.field_behavior) = IMMUTABLE,
2600+
(google.api.field_behavior) = REQUIRED,
2601+
(google.api.resource_reference) = {
2602+
type: "compute.googleapis.com/NetworkAttachment"
2603+
}
2604+
];
2605+
2606+
// Required. Immutable. Disable public IP on the primary network interface.
2607+
//
2608+
// If true, workers are created without any public address, which prevents
2609+
// network egress to public IPs unless a network proxy is configured.
2610+
// If false, workers are created with a public address which allows for
2611+
// public internet egress. The public address only applies to traffic
2612+
// through the primary network interface.
2613+
// If `route_all_traffic` is set to true, all traffic will go through the
2614+
// non-primary network interface, this boolean has no effect.
2615+
bool public_ip_address_disabled = 2 [
2616+
(google.api.field_behavior) = REQUIRED,
2617+
(google.api.field_behavior) = IMMUTABLE
2618+
];
2619+
2620+
// Immutable. Route all traffic through PSC interface. Enable this if you
2621+
// want full control of traffic in the private pool. Configure Cloud NAT for
2622+
// the subnet of network attachment if you need to access public Internet.
2623+
//
2624+
// If false, Only route private IPs, e.g. 10.0.0.0/8, 172.16.0.0/12, and
2625+
// 192.168.0.0/16 through PSC interface.
2626+
bool route_all_traffic = 3 [(google.api.field_behavior) = IMMUTABLE];
2627+
}
2628+
25862629
// Machine configuration for the workers in the pool.
25872630
WorkerConfig worker_config = 1;
25882631

25892632
// Network configuration for the pool.
25902633
NetworkConfig network_config = 2;
2634+
2635+
// Immutable. Private Service Connect(PSC) Network configuration for the pool.
2636+
PrivateServiceConnect private_service_connect = 5
2637+
[(google.api.field_behavior) = IMMUTABLE];
25912638
}
25922639

25932640
// Request to create a new `WorkerPool`.

0 commit comments

Comments
 (0)