ComputeServiceAttachment
Property | Value |
---|---|
Google Cloud Service Name | Compute Engine |
Google Cloud Service Documentation | /compute/docs/ |
Google Cloud REST Resource Name | beta.serviceAttachments |
Google Cloud REST Resource Documentation | /compute/docs/reference/rest/beta/serviceAttachments |
Config Connector Resource Short Names | gcpcomputeserviceattachment gcpcomputeserviceattachments computeserviceattachment |
Config Connector Service Name | compute.googleapis.com |
Config Connector Resource Fully Qualified Name | computeserviceattachments.compute.cnrm.cloud.google.com |
Can Be Referenced by IAMPolicy/IAMPolicyMember | No |
Config Connector Default Average Reconcile Interval In Seconds | 600 |
Custom Resource Definition Properties
Spec
Schema
connectionPreference: string
consumerAcceptLists:
- connectionLimit: integer
projectRef:
external: string
name: string
namespace: string
consumerRejectLists:
- external: string
name: string
namespace: string
description: string
enableProxyProtocol: boolean
location: string
natSubnets:
- external: string
name: string
namespace: string
projectRef:
external: string
name: string
namespace: string
resourceID: string
targetServiceRef:
external: string
name: string
namespace: string
Fields | |
---|---|
Required |
The connection preference of service attachment. The value can be set to `ACCEPT_AUTOMATIC`. An `ACCEPT_AUTOMATIC` service attachment is one that always accepts the connection from consumer forwarding rules. Possible values: CONNECTION_PREFERENCE_UNSPECIFIED, ACCEPT_AUTOMATIC, ACCEPT_MANUAL |
Optional |
Projects that are allowed to connect to this service attachment. |
Optional |
|
Optional |
The value of the limit to set. |
Required* |
|
Optional |
The project id or number for the project to set the limit for. Allowed value: The Google Cloud resource name of a `Project` resource (format: `projects/{{name}}`). |
Optional |
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names |
Optional |
Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ |
Optional |
|
Optional |
|
Optional |
Allowed value: The Google Cloud resource name of a `Project` resource (format: `projects/{{name}}`). |
Optional |
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names |
Optional |
Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ |
Optional |
An optional description of this resource. Provide this property when you create the resource. |
Optional |
Immutable. If true, enable the proxy protocol which is for supplying client TCP/IP address data in TCP connections that traverse proxies on their way to destination servers. |
Required |
Immutable. The location for the resource |
Required |
|
Required |
|
Optional |
Allowed value: The `selfLink` field of a `ComputeSubnetwork` resource. |
Optional |
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names |
Optional |
Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ |
Required |
Immutable. The Project that this resource belongs to. |
Optional |
The project for the resource Allowed value: The Google Cloud resource name of a `Project` resource (format: `projects/{{name}}`). |
Optional |
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names |
Optional |
Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ |
Optional |
Immutable. Optional. The name of the resource. Used for creation and acquisition. When unset, the value of `metadata.name` is used as the default. |
Required |
Immutable. |
Optional |
The URL of a service serving the endpoint identified by this service attachment. Allowed value: The `selfLink` field of a `ComputeForwardingRule` resource. |
Optional |
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names |
Optional |
Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ |
* Field is required when parent field is specified
Status
Schema
conditions:
- lastTransitionTime: string
message: string
reason: string
status: string
type: string
connectedEndpoints:
- endpoint: string
pscConnectionId: integer
status: string
fingerprint: string
id: integer
observedGeneration: integer
pscServiceAttachmentId:
high: integer
low: integer
region: string
selfLink: string
Fields | |
---|---|
conditions |
Conditions represent the latest available observation of the resource's current state. |
conditions[] |
|
conditions[].lastTransitionTime |
Last time the condition transitioned from one status to another. |
conditions[].message |
Human-readable message indicating details about last transition. |
conditions[].reason |
Unique, one-word, CamelCase reason for the condition's last transition. |
conditions[].status |
Status is the status of the condition. Can be True, False, Unknown. |
conditions[].type |
Type is the type of the condition. |
connectedEndpoints |
An array of connections for all the consumers connected to this service attachment. |
connectedEndpoints[] |
|
connectedEndpoints[].endpoint |
The url of a connected endpoint. |
connectedEndpoints[].pscConnectionId |
The PSC connection id of the connected endpoint. |
connectedEndpoints[].status |
The status of a connected endpoint to this service attachment. Possible values: PENDING, RUNNING, DONE |
fingerprint |
Fingerprint of this resource. This field is used internally during updates of this resource. |
id |
The unique identifier for the resource type. The server generates this identifier. |
observedGeneration |
ObservedGeneration is the generation of the resource that was most recently observed by the Config Connector controller. If this is equal to metadata.generation, then that means that the current reported status reflects the most recent desired state of the resource. |
pscServiceAttachmentId |
An 128-bit global unique ID of the PSC service attachment. |
pscServiceAttachmentId.high |
|
pscServiceAttachmentId.low |
|
region |
URL of the region where the service attachment resides. This field applies only to the region resource. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. |
selfLink |
Server-defined URL for the resource. |
Sample YAML(s)
Typical Use Case
# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
apiVersion: compute.cnrm.cloud.google.com/v1beta1
kind: ComputeServiceAttachment
metadata:
name: computeserviceattachment-sample
spec:
projectRef:
# Replace ${PROJECT_ID?} with your project ID
external: "projects/${PROJECT_ID?}"
location: "us-west2"
description: "A sample service attachment"
targetServiceRef:
name: "computeserviceattachment-dep"
connectionPreference: "ACCEPT_MANUAL"
natSubnets:
- name: "computeserviceattachment-dep1"
enableProxyProtocol: false
consumerRejectLists:
- name: "computeserviceattachment-dep1"
consumerAcceptLists:
- projectRef:
name: "computeserviceattachment-dep2"
connectionLimit: 2
---
apiVersion: compute.cnrm.cloud.google.com/v1beta1
kind: ComputeBackendService
metadata:
name: computeserviceattachment-dep
spec:
location: "us-west2"
networkRef:
name: "computeserviceattachment-dep"
loadBalancingScheme: "INTERNAL"
---
apiVersion: compute.cnrm.cloud.google.com/v1beta1
kind: ComputeForwardingRule
metadata:
name: computeserviceattachment-dep
spec:
location: "us-west2"
networkRef:
name: "computeserviceattachment-dep"
subnetworkRef:
name: "computeserviceattachment-dep3"
description: "A test forwarding rule with internal load balancing scheme"
loadBalancingScheme: "INTERNAL"
backendServiceRef:
name: "computeserviceattachment-dep"
networkTier: "PREMIUM"
allPorts: true
---
apiVersion: compute.cnrm.cloud.google.com/v1beta1
kind: ComputeNetwork
metadata:
name: computeserviceattachment-dep
spec:
autoCreateSubnetworks: false
---
apiVersion: compute.cnrm.cloud.google.com/v1beta1
kind: ComputeSubnetwork
metadata:
name: computeserviceattachment-dep1
spec:
region: "us-west2"
ipCidrRange: "10.2.0.0/16"
networkRef:
name: "computeserviceattachment-dep"
purpose: "PRIVATE_SERVICE_CONNECT"
---
apiVersion: compute.cnrm.cloud.google.com/v1beta1
kind: ComputeSubnetwork
metadata:
name: computeserviceattachment-dep2
spec:
region: "us-west2"
ipCidrRange: "10.3.0.0/16"
networkRef:
name: "computeserviceattachment-dep"
purpose: "PRIVATE_SERVICE_CONNECT"
---
apiVersion: compute.cnrm.cloud.google.com/v1beta1
kind: ComputeSubnetwork
metadata:
name: computeserviceattachment-dep3
spec:
region: "us-west2"
ipCidrRange: "10.4.0.0/16"
networkRef:
name: "computeserviceattachment-dep"
purpose: "PRIVATE"
---
apiVersion: resourcemanager.cnrm.cloud.google.com/v1beta1
kind: Project
metadata:
name: computeserviceattachment-dep1
spec:
organizationRef:
# Replace "${ORG_ID?}" with the numeric ID for your organization
external: "${ORG_ID?}"
name: "computeserviceattachment-dep1"
---
apiVersion: resourcemanager.cnrm.cloud.google.com/v1beta1
kind: Project
metadata:
name: computeserviceattachment-dep2
spec:
organizationRef:
# Replace "${ORG_ID?}" with the numeric ID for your organization
external: "${ORG_ID?}"
name: "computeserviceattachment-dep2"