xpn_hosts
Creates, updates, deletes, gets or lists a xpn_hosts
resource.
Overview
Name | xpn_hosts |
Type | Resource |
Id | google.compute.xpn_hosts |
Fields
The following fields are returned by SELECT
queries:
- list_xpn_hosts
- get_xpn_host
Successful response
Name | Datatype | Description |
---|---|---|
id | string | [Output Only] Unique identifier for the resource; defined by the server. |
items | array | [Output Only] A list of shared VPC host project URLs. |
kind | string | [Output Only] Type of resource. Always compute#xpnHostList for lists of shared VPC hosts. (default: compute#xpnHostList) |
nextPageToken | string | [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. |
selfLink | string | [Output Only] Server-defined URL for this resource. |
warning | object | [Output Only] Informational warning message. |
Successful response
Name | Datatype | Description |
---|---|---|
id | string (uint64) | [Output Only] The unique identifier for the resource. This identifier is defined by the server. This is not the project ID, and is just a unique ID used by Compute Engine to identify resources. |
name | string | The project ID. For example: my-example-project. Use the project ID to make requests to Compute Engine. |
cloudArmorTier | string | [Output Only] The Cloud Armor tier for this project. It can be one of the following values: CA_STANDARD, CA_ENTERPRISE_PAYGO. If this field is not specified, it is assumed to be CA_STANDARD. |
commonInstanceMetadata | object | Metadata key/value pairs available to all instances contained in this project. See Custom metadata for more information. (id: Metadata) |
creationTimestamp | string | [Output Only] Creation timestamp in RFC3339 text format. |
defaultNetworkTier | string | This signifies the default network tier used for configuring resources of the project and can only take the following values: PREMIUM, STANDARD. Initially the default network tier is PREMIUM. |
defaultServiceAccount | string | [Output Only] Default service account used by VMs running in this project. |
description | string | An optional textual description of the resource. |
enabledFeatures | array | An optional list of restricted features enabled for use on this project. |
kind | string | [Output Only] Type of the resource. Always compute#project for projects. (default: compute#project) |
quotas | array | [Output Only] Quotas assigned to this project. |
selfLink | string | [Output Only] Server-defined URL for the resource. |
usageExportLocation | object | An optional naming prefix for daily usage reports and the Google Cloud Storage bucket where they are stored. (id: UsageExportLocation) |
vmDnsSetting | string | [Output Only] Default internal DNS setting used by VMs running in this project. |
xpnProjectStatus | string | [Output Only] The role this project has in a shared VPC configuration. Currently, only projects with the host role, which is specified by the value HOST, are differentiated. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
list_xpn_hosts | select | project | filter , maxResults , orderBy , pageToken , returnPartialSuccess | Lists all shared VPC host projects visible to the user in an organization. |
get_xpn_host | select | project | Gets the shared VPC host project that this project links to. May be empty if no link exists. |
Parameters
Parameters can be passed in the WHERE
clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
Name | Datatype | Description |
---|---|---|
project | string | |
filter | string | |
maxResults | integer (uint32) | |
orderBy | string | |
pageToken | string | |
returnPartialSuccess | boolean |
SELECT
examples
- list_xpn_hosts
- get_xpn_host
Lists all shared VPC host projects visible to the user in an organization.
SELECT
id,
items,
kind,
nextPageToken,
selfLink,
warning
FROM google.compute.xpn_hosts
WHERE project = '{{ project }}' -- required
AND filter = '{{ filter }}'
AND maxResults = '{{ maxResults }}'
AND orderBy = '{{ orderBy }}'
AND pageToken = '{{ pageToken }}'
AND returnPartialSuccess = '{{ returnPartialSuccess }}';
Gets the shared VPC host project that this project links to. May be empty if no link exists.
SELECT
id,
name,
cloudArmorTier,
commonInstanceMetadata,
creationTimestamp,
defaultNetworkTier,
defaultServiceAccount,
description,
enabledFeatures,
kind,
quotas,
selfLink,
usageExportLocation,
vmDnsSetting,
xpnProjectStatus
FROM google.compute.xpn_hosts
WHERE project = '{{ project }}' -- required;