Class: Google::Apis::ConfigV1::Preview
- Inherits:
-
Object
- Object
- Google::Apis::ConfigV1::Preview
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/config_v1/classes.rb,
lib/google/apis/config_v1/representations.rb,
lib/google/apis/config_v1/representations.rb
Overview
A preview represents a set of actions Infra Manager would perform to move the resources towards the desired state as specified in the configuration.
Instance Attribute Summary collapse
-
#annotations ⇒ Hash<String,String>
Optional.
-
#artifacts_gcs_bucket ⇒ String
Optional.
-
#build ⇒ String
Output only.
-
#create_time ⇒ String
Output only.
-
#deployment ⇒ String
Optional.
-
#error_code ⇒ String
Output only.
-
#error_logs ⇒ String
Output only.
-
#error_status ⇒ Google::Apis::ConfigV1::Status
The
Status
type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. -
#labels ⇒ Hash<String,String>
Optional.
-
#logs ⇒ String
Output only.
-
#name ⇒ String
Identifier.
-
#preview_artifacts ⇒ Google::Apis::ConfigV1::PreviewArtifacts
Artifacts created by preview.
-
#preview_mode ⇒ String
Optional.
-
#service_account ⇒ String
Optional.
-
#state ⇒ String
Output only.
-
#terraform_blueprint ⇒ Google::Apis::ConfigV1::TerraformBlueprint
TerraformBlueprint describes the source of a Terraform root module which describes the resources and configs to be deployed.
-
#tf_errors ⇒ Array<Google::Apis::ConfigV1::TerraformError>
Output only.
-
#tf_version ⇒ String
Output only.
-
#tf_version_constraint ⇒ String
Optional.
-
#worker_pool ⇒ String
Optional.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Preview
constructor
A new instance of Preview.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Preview
Returns a new instance of Preview.
1350 1351 1352 |
# File 'lib/google/apis/config_v1/classes.rb', line 1350 def initialize(**args) update!(**args) end |
Instance Attribute Details
#annotations ⇒ Hash<String,String>
Optional. Arbitrary key-value metadata storage e.g. to help client tools
identifiy preview during automation. See https://google.aip.dev/148#
annotations for details on format and size limitations.
Corresponds to the JSON property annotations
1226 1227 1228 |
# File 'lib/google/apis/config_v1/classes.rb', line 1226 def annotations @annotations end |
#artifacts_gcs_bucket ⇒ String
Optional. User-defined location of Cloud Build logs, artifacts, and in Google
Cloud Storage. Format: gs://
bucket/
folder`A default bucket will be
bootstrapped if the field is not set or empty Default Bucket Format:
gs://--
blueprint-configConstraints: - The bucket needs to be in the same project as
the deployment - The path cannot be within the path of
gcs_sourceIf omitted
and deployment resource ref provided has artifacts_gcs_bucket defined, that
artifact bucket is used.
Corresponds to the JSON property
artifactsGcsBucket`
1237 1238 1239 |
# File 'lib/google/apis/config_v1/classes.rb', line 1237 def artifacts_gcs_bucket @artifacts_gcs_bucket end |
#build ⇒ String
Output only. Cloud Build instance UUID associated with this preview.
Corresponds to the JSON property build
1242 1243 1244 |
# File 'lib/google/apis/config_v1/classes.rb', line 1242 def build @build end |
#create_time ⇒ String
Output only. Time the preview was created.
Corresponds to the JSON property createTime
1247 1248 1249 |
# File 'lib/google/apis/config_v1/classes.rb', line 1247 def create_time @create_time end |
#deployment ⇒ String
Optional. Optional deployment reference. If specified, the preview will be
performed using the provided deployment's current state and use any relevant
fields from the deployment unless explicitly specified in the preview create
request.
Corresponds to the JSON property deployment
1255 1256 1257 |
# File 'lib/google/apis/config_v1/classes.rb', line 1255 def deployment @deployment end |
#error_code ⇒ String
Output only. Code describing any errors that may have occurred.
Corresponds to the JSON property errorCode
1260 1261 1262 |
# File 'lib/google/apis/config_v1/classes.rb', line 1260 def error_code @error_code end |
#error_logs ⇒ String
Output only. Link to tf-error.ndjson file, which contains the full list of the
errors encountered during a Terraform preview. Format: gs://
bucket/
object`
.
Corresponds to the JSON property
errorLogs`
1267 1268 1269 |
# File 'lib/google/apis/config_v1/classes.rb', line 1267 def error_logs @error_logs end |
#error_status ⇒ Google::Apis::ConfigV1::Status
The Status
type defines a logical error model that is suitable for different
programming environments, including REST APIs and RPC APIs. It is used by
gRPC. Each Status
message contains three pieces of
data: error code, error message, and error details. You can find out more
about this error model and how to work with it in the API Design Guide.
Corresponds to the JSON property errorStatus
1277 1278 1279 |
# File 'lib/google/apis/config_v1/classes.rb', line 1277 def error_status @error_status end |
#labels ⇒ Hash<String,String>
Optional. User-defined labels for the preview.
Corresponds to the JSON property labels
1282 1283 1284 |
# File 'lib/google/apis/config_v1/classes.rb', line 1282 def labels @labels end |
#logs ⇒ String
Output only. Location of preview logs in gs://
bucket/
object`format.
Corresponds to the JSON property
logs`
1287 1288 1289 |
# File 'lib/google/apis/config_v1/classes.rb', line 1287 def logs @logs end |
#name ⇒ String
Identifier. Resource name of the preview. Resource name can be user provided
or server generated ID if unspecified. Format: projects/
project/locations/
location/previews/
preview`
Corresponds to the JSON property
name`
1294 1295 1296 |
# File 'lib/google/apis/config_v1/classes.rb', line 1294 def name @name end |
#preview_artifacts ⇒ Google::Apis::ConfigV1::PreviewArtifacts
Artifacts created by preview.
Corresponds to the JSON property previewArtifacts
1299 1300 1301 |
# File 'lib/google/apis/config_v1/classes.rb', line 1299 def preview_artifacts @preview_artifacts end |
#preview_mode ⇒ String
Optional. Current mode of preview.
Corresponds to the JSON property previewMode
1304 1305 1306 |
# File 'lib/google/apis/config_v1/classes.rb', line 1304 def preview_mode @preview_mode end |
#service_account ⇒ String
Optional. User-specified Service Account (SA) credentials to be used when
previewing resources. Format: projects/
projectID/serviceAccounts/
serviceAccount`
Corresponds to the JSON property
serviceAccount`
1311 1312 1313 |
# File 'lib/google/apis/config_v1/classes.rb', line 1311 def service_account @service_account end |
#state ⇒ String
Output only. Current state of the preview.
Corresponds to the JSON property state
1316 1317 1318 |
# File 'lib/google/apis/config_v1/classes.rb', line 1316 def state @state end |
#terraform_blueprint ⇒ Google::Apis::ConfigV1::TerraformBlueprint
TerraformBlueprint describes the source of a Terraform root module which
describes the resources and configs to be deployed.
Corresponds to the JSON property terraformBlueprint
1322 1323 1324 |
# File 'lib/google/apis/config_v1/classes.rb', line 1322 def terraform_blueprint @terraform_blueprint end |
#tf_errors ⇒ Array<Google::Apis::ConfigV1::TerraformError>
Output only. Summary of errors encountered during Terraform preview. It has a
size limit of 10, i.e. only top 10 errors will be summarized here.
Corresponds to the JSON property tfErrors
1328 1329 1330 |
# File 'lib/google/apis/config_v1/classes.rb', line 1328 def tf_errors @tf_errors end |
#tf_version ⇒ String
Output only. The current Terraform version set on the preview. It is in the
format of "Major.Minor.Patch", for example, "1.3.10".
Corresponds to the JSON property tfVersion
1334 1335 1336 |
# File 'lib/google/apis/config_v1/classes.rb', line 1334 def tf_version @tf_version end |
#tf_version_constraint ⇒ String
Optional. The user-specified Terraform version constraint. Example: "=1.3.10".
Corresponds to the JSON property tfVersionConstraint
1339 1340 1341 |
# File 'lib/google/apis/config_v1/classes.rb', line 1339 def tf_version_constraint @tf_version_constraint end |
#worker_pool ⇒ String
Optional. The user-specified 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. If omitted and deployment resource ref provided has
worker_pool defined, that worker pool is used.
Corresponds to the JSON property workerPool
1348 1349 1350 |
# File 'lib/google/apis/config_v1/classes.rb', line 1348 def worker_pool @worker_pool end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 |
# File 'lib/google/apis/config_v1/classes.rb', line 1355 def update!(**args) @annotations = args[:annotations] if args.key?(:annotations) @artifacts_gcs_bucket = args[:artifacts_gcs_bucket] if args.key?(:artifacts_gcs_bucket) @build = args[:build] if args.key?(:build) @create_time = args[:create_time] if args.key?(:create_time) @deployment = args[:deployment] if args.key?(:deployment) @error_code = args[:error_code] if args.key?(:error_code) @error_logs = args[:error_logs] if args.key?(:error_logs) @error_status = args[:error_status] if args.key?(:error_status) @labels = args[:labels] if args.key?(:labels) @logs = args[:logs] if args.key?(:logs) @name = args[:name] if args.key?(:name) @preview_artifacts = args[:preview_artifacts] if args.key?(:preview_artifacts) @preview_mode = args[:preview_mode] if args.key?(:preview_mode) @service_account = args[:service_account] if args.key?(:service_account) @state = args[:state] if args.key?(:state) @terraform_blueprint = args[:terraform_blueprint] if args.key?(:terraform_blueprint) @tf_errors = args[:tf_errors] if args.key?(:tf_errors) @tf_version = args[:tf_version] if args.key?(:tf_version) @tf_version_constraint = args[:tf_version_constraint] if args.key?(:tf_version_constraint) @worker_pool = args[:worker_pool] if args.key?(:worker_pool) end |