Skip to main content

revisions

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

Overview

Namerevisions
TypeResource
Idgoogle.config.revisions

Fields

NameDatatypeDescription
namestringRevision name. Format: projects/{project}/locations/{location}/deployments/{deployment}/ revisions/{revision}
actionstringOutput only. The action which created this revision
applyResultsobjectOutputs and artifacts from applying a deployment.
buildstringOutput only. Cloud Build instance UUID associated with this revision.
createTimestringOutput only. Time when the revision was created.
errorCodestringOutput only. Code describing any errors that may have occurred.
errorLogsstringOutput only. Location of Terraform error logs in Google Cloud Storage. Format: gs://{bucket}/{object}.
importExistingResourcesbooleanOutput only. By default, Infra Manager will return a failure when Terraform encounters a 409 code (resource conflict error) during actuation. If this flag is set to true, Infra Manager will instead attempt to automatically import the resource into the Terraform state (for supported resource types) and continue actuation. Not all resource types are supported, refer to documentation.
logsstringOutput only. Location of Revision operation logs in gs://{bucket}/{object} format.
quotaValidationstringOptional. Input to control quota checks for resources in terraform configuration files. There are limited resources on which quota validation applies.
quotaValidationResultsstringOutput only. Cloud Storage path containing quota validation results. This field is set when a user sets Deployment.quota_validation field to ENABLED or ENFORCED. Format: gs://{bucket}/{object}.
serviceAccountstringOutput only. User-specified Service Account (SA) to be used as credential to manage resources. Format: projects/{projectID}/serviceAccounts/{serviceAccount}
statestringOutput only. Current state of the revision.
stateDetailstringOutput only. Additional info regarding the current state.
terraformBlueprintobjectTerraformBlueprint describes the source of a Terraform root module which describes the resources and configs to be deployed.
tfErrorsarrayOutput only. Errors encountered when creating or updating this deployment. Errors are truncated to 10 entries, see delete_results and error_logs for full details.
tfVersionstringOutput only. The version of Terraform used to create the Revision. It is in the format of "Major.Minor.Patch", for example, "1.3.10".
tfVersionConstraintstringOutput only. The user-specified Terraform version constraint. Example: "=1.3.10".
updateTimestringOutput only. Time when the revision was last modified.
workerPoolstringOutput only. The user-specified Cloud Build worker pool resource in which the Cloud Build job will execute. Format: projects/{project}/locations/{location}/workerPools/{workerPoolId}. If this field is unspecified, the default Cloud Build worker pool will be used.

Methods

NameAccessible byRequired ParamsDescription
getSELECTdeploymentsId, locationsId, projectsId, revisionsIdGets details about a Revision.
listSELECTdeploymentsId, locationsId, projectsIdLists Revisions of a deployment.
export_stateEXECdeploymentsId, locationsId, projectsId, revisionsIdExports Terraform state file from a given revision.

SELECT examples

Lists Revisions of a deployment.

SELECT
name,
action,
applyResults,
build,
createTime,
errorCode,
errorLogs,
importExistingResources,
logs,
quotaValidation,
quotaValidationResults,
serviceAccount,
state,
stateDetail,
terraformBlueprint,
tfErrors,
tfVersion,
tfVersionConstraint,
updateTime,
workerPool
FROM google.config.revisions
WHERE deploymentsId = '{{ deploymentsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';