Skip to main content

image_import_jobs

Creates, updates, deletes, gets or lists an image_import_jobs resource.

Overview

Nameimage_import_jobs
TypeResource
Idgoogle.vmmigration.image_import_jobs

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
namestringOutput only. The resource path of the ImageImportJob.
cloudStorageUristringOutput only. The path to the Cloud Storage file from which the image should be imported.
createTimestring (google-datetime)Output only. The time the image import was created (as an API call, not when it was actually created in the target).
createdResourcesarrayOutput only. The resource paths of the resources created by the image import job.
diskImageTargetDetailsobjectOutput only. Target details used to import a disk image. (id: DiskImageTargetDetails)
endTimestring (google-datetime)Output only. The time the image import was ended.
errorsarrayOutput only. Provides details on the error that led to the image import state in case of an error.
machineImageTargetDetailsobjectOutput only. Target details used to import a machine image. (id: MachineImageTargetDetails)
statestringOutput only. The state of the image import.
stepsarrayOutput only. The image import steps list representing its progress.
warningsarrayOutput only. Warnings that occurred during the image import.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, imageImportsId, imageImportJobsIdGets details of a single ImageImportJob.
listselectprojectsId, locationsId, imageImportsIdpageSize, pageToken, filter, orderByLists ImageImportJobs in a given project.
cancelexecprojectsId, locationsId, imageImportsId, imageImportJobsIdInitiates the cancellation of a running clone job.

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.

NameDatatypeDescription
imageImportJobsIdstring
imageImportsIdstring
locationsIdstring
projectsIdstring
filterstring
orderBystring
pageSizeinteger (int32)
pageTokenstring

SELECT examples

Gets details of a single ImageImportJob.

SELECT
name,
cloudStorageUri,
createTime,
createdResources,
diskImageTargetDetails,
endTime,
errors,
machineImageTargetDetails,
state,
steps,
warnings
FROM google.vmmigration.image_import_jobs
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND imageImportsId = '{{ imageImportsId }}' -- required
AND imageImportJobsId = '{{ imageImportJobsId }}' -- required;

Lifecycle Methods

Initiates the cancellation of a running clone job.

EXEC google.vmmigration.image_import_jobs.cancel 
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@imageImportsId='{{ imageImportsId }}' --required,
@imageImportJobsId='{{ imageImportJobsId }}' --required;