Skip to main content

bare_metal_admin_clusters

Creates, updates, deletes, gets or lists a bare_metal_admin_clusters resource.

Overview

Namebare_metal_admin_clusters
TypeResource
Idgoogle.gkeonprem.bare_metal_admin_clusters

Fields

NameDatatypeDescription
namestringImmutable. The bare metal admin cluster resource name.
descriptionstringA human readable description of this bare metal admin cluster.
annotationsobjectAnnotations on the bare metal admin cluster. This field has the same restrictions as Kubernetes annotations. The total size of all keys and values combined is limited to 256k. Key can have 2 segments: prefix (optional) and name (required), separated by a slash (/). Prefix must be a DNS subdomain. Name must be 63 characters or less, begin and end with alphanumerics, with dashes (-), underscores (_), dots (.), and alphanumerics between.
bareMetalVersionstringThe Anthos clusters on bare metal version for the bare metal admin cluster.
binaryAuthorizationobjectConfiguration for Binary Authorization.
clusterOperationsobjectBareMetalAdminClusterOperationsConfig specifies the admin cluster's observability infrastructure.
controlPlaneobjectBareMetalAdminControlPlaneConfig specifies the control plane configuration.
createTimestringOutput only. The time at which this bare metal admin cluster was created.
deleteTimestringOutput only. The time at which this bare metal admin cluster was deleted. If the resource is not deleted, this must be empty
endpointstringOutput only. The IP address name of bare metal admin cluster's API server.
etagstringThis checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding. Allows clients to perform consistent read-modify-writes through optimistic concurrency control.
fleetobjectFleet related configuration. Fleets are a Google Cloud concept for logically organizing clusters, letting you use and manage multi-cluster capabilities and apply consistent policies across your systems. See Anthos Fleets for more details on Anthos multi-cluster capabilities using Fleets. ##
loadBalancerobjectBareMetalAdminLoadBalancerConfig specifies the load balancer configuration.
localNamestringOutput only. The object name of the bare metal cluster custom resource. This field is used to support conflicting names when enrolling existing clusters to the API. When used as a part of cluster enrollment, this field will differ from the ID in the resource name. For new clusters, this field will match the user provided cluster name and be visible in the last component of the resource name. It is not modifiable. All users should use this name to access their cluster using gkectl or kubectl and should expect to see the local name when viewing admin cluster controller logs.
maintenanceConfigobjectBareMetalAdminMaintenanceConfig specifies configurations to put bare metal Admin cluster CRs nodes in and out of maintenance.
maintenanceStatusobjectBareMetalAdminMaintenanceStatus represents the maintenance status for bare metal Admin cluster CR's nodes.
networkConfigobjectBareMetalAdminNetworkConfig specifies the cluster network configuration.
nodeAccessConfigobjectSpecifies the node access related settings for the bare metal admin cluster.
nodeConfigobjectBareMetalAdminWorkloadNodeConfig specifies the workload node configurations.
osEnvironmentConfigobjectSpecifies operating system operation settings for cluster provisioning.
proxyobjectBareMetalAdminProxyConfig specifies the cluster proxy configuration.
reconcilingbooleanOutput only. If set, there are currently changes in flight to the bare metal Admin Cluster.
securityConfigobjectSpecifies the security related settings for the bare metal admin cluster.
statestringOutput only. The current state of the bare metal admin cluster.
statusobjectResourceStatus describes why a cluster or node pool has a certain status. (e.g., ERROR or DEGRADED).
storageobjectBareMetalAdminStorageConfig specifies the cluster storage configuration.
uidstringOutput only. The unique identifier of the bare metal admin cluster.
updateTimestringOutput only. The time at which this bare metal admin cluster was last updated.
validationCheckobjectValidationCheck represents the result of preflight check.

Methods

NameAccessible byRequired ParamsDescription
projects_locations_bare_metal_admin_clusters_getSELECTbareMetalAdminClustersId, locationsId, projectsIdGets details of a single bare metal admin cluster.
projects_locations_bare_metal_admin_clusters_listSELECTlocationsId, projectsIdLists bare metal admin clusters in a given project and location.
projects_locations_bare_metal_admin_clusters_createINSERTlocationsId, projectsIdCreates a new bare metal admin cluster in a given project and location. The API needs to be combined with creating a bootstrap cluster to work. See: https://cloud.google.com/anthos/clusters/docs/bare-metal/latest/installing/creating-clusters/create-admin-cluster-api#prepare_bootstrap_environment
projects_locations_bare_metal_admin_clusters_patchUPDATEbareMetalAdminClustersId, locationsId, projectsIdUpdates the parameters of a single bare metal admin cluster.
projects_locations_bare_metal_admin_clusters_enrollEXEClocationsId, projectsIdEnrolls an existing bare metal admin cluster to the Anthos On-Prem API within a given project and location. Through enrollment, an existing admin cluster will become Anthos On-Prem API managed. The corresponding GCP resources will be created and all future modifications to the cluster will be expected to be performed through the API.
projects_locations_bare_metal_admin_clusters_query_version_configEXEClocationsId, projectsIdQueries the bare metal admin cluster version config.
projects_locations_bare_metal_admin_clusters_unenrollEXECbareMetalAdminClustersId, locationsId, projectsIdUnenrolls an existing bare metal admin cluster from the Anthos On-Prem API within a given project and location. Unenrollment removes the Cloud reference to the cluster without modifying the underlying OnPrem Resources. Clusters will continue to run; however, they will no longer be accessible through the Anthos On-Prem API or its clients.

SELECT examples

Lists bare metal admin clusters in a given project and location.

SELECT
name,
description,
annotations,
bareMetalVersion,
binaryAuthorization,
clusterOperations,
controlPlane,
createTime,
deleteTime,
endpoint,
etag,
fleet,
loadBalancer,
localName,
maintenanceConfig,
maintenanceStatus,
networkConfig,
nodeAccessConfig,
nodeConfig,
osEnvironmentConfig,
proxy,
reconciling,
securityConfig,
state,
status,
storage,
uid,
updateTime,
validationCheck
FROM google.gkeonprem.bare_metal_admin_clusters
WHERE locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';

INSERT example

Use the following StackQL query and manifest file to create a new bare_metal_admin_clusters resource.

/*+ create */
INSERT INTO google.gkeonprem.bare_metal_admin_clusters (
locationsId,
projectsId,
name,
description,
bareMetalVersion,
etag,
annotations,
networkConfig,
controlPlane,
loadBalancer,
storage,
clusterOperations,
maintenanceConfig,
nodeConfig,
proxy,
securityConfig,
nodeAccessConfig,
osEnvironmentConfig,
binaryAuthorization
)
SELECT
'{{ locationsId }}',
'{{ projectsId }}',
'{{ name }}',
'{{ description }}',
'{{ bareMetalVersion }}',
'{{ etag }}',
'{{ annotations }}',
'{{ networkConfig }}',
'{{ controlPlane }}',
'{{ loadBalancer }}',
'{{ storage }}',
'{{ clusterOperations }}',
'{{ maintenanceConfig }}',
'{{ nodeConfig }}',
'{{ proxy }}',
'{{ securityConfig }}',
'{{ nodeAccessConfig }}',
'{{ osEnvironmentConfig }}',
'{{ binaryAuthorization }}'
;

UPDATE example

Updates a bare_metal_admin_clusters resource.

/*+ update */
UPDATE google.gkeonprem.bare_metal_admin_clusters
SET
name = '{{ name }}',
description = '{{ description }}',
bareMetalVersion = '{{ bareMetalVersion }}',
etag = '{{ etag }}',
annotations = '{{ annotations }}',
networkConfig = '{{ networkConfig }}',
controlPlane = '{{ controlPlane }}',
loadBalancer = '{{ loadBalancer }}',
storage = '{{ storage }}',
clusterOperations = '{{ clusterOperations }}',
maintenanceConfig = '{{ maintenanceConfig }}',
nodeConfig = '{{ nodeConfig }}',
proxy = '{{ proxy }}',
securityConfig = '{{ securityConfig }}',
nodeAccessConfig = '{{ nodeAccessConfig }}',
osEnvironmentConfig = '{{ osEnvironmentConfig }}',
binaryAuthorization = '{{ binaryAuthorization }}'
WHERE
bareMetalAdminClustersId = '{{ bareMetalAdminClustersId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';