image_imports
Creates, updates, deletes, gets or lists an image_imports
resource.
Overview
Name | image_imports |
Type | Resource |
Id | google.vmmigration.image_imports |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Output only. The resource path of the ImageImport. |
cloudStorageUri | string | Immutable. The path to the Cloud Storage file from which the image should be imported. |
createTime | string (google-datetime) | Output only. The time the image import was created. |
diskImageTargetDefaults | object | Immutable. Target details for importing a disk image, will be used by ImageImportJob. (id: DiskImageTargetDetails) |
encryption | object | Immutable. The encryption details used by the image import process during the image adaptation for Compute Engine. (id: Encryption) |
machineImageTargetDefaults | object | Immutable. Target details for importing a machine image, will be used by ImageImportJob. (id: MachineImageTargetDetails) |
recentImageImportJobs | array | Output only. The result of the most recent runs for this ImageImport. All jobs for this ImageImport can be listed via ListImageImportJobs. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Output only. The resource path of the ImageImport. |
cloudStorageUri | string | Immutable. The path to the Cloud Storage file from which the image should be imported. |
createTime | string (google-datetime) | Output only. The time the image import was created. |
diskImageTargetDefaults | object | Immutable. Target details for importing a disk image, will be used by ImageImportJob. (id: DiskImageTargetDetails) |
encryption | object | Immutable. The encryption details used by the image import process during the image adaptation for Compute Engine. (id: Encryption) |
machineImageTargetDefaults | object | Immutable. Target details for importing a machine image, will be used by ImageImportJob. (id: MachineImageTargetDetails) |
recentImageImportJobs | array | Output only. The result of the most recent runs for this ImageImport. All jobs for this ImageImport can be listed via ListImageImportJobs. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , locationsId , imageImportsId | Gets details of a single ImageImport. | |
list | select | projectsId , locationsId | pageSize , pageToken , filter , orderBy | Lists ImageImports in a given project. |
create | insert | projectsId , locationsId | imageImportId , requestId | Creates a new ImageImport in a given project. |
delete | delete | projectsId , locationsId , imageImportsId | requestId | Deletes a single ImageImport. |
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 |
---|---|---|
imageImportsId | string | |
locationsId | string | |
projectsId | string | |
filter | string | |
imageImportId | string | |
orderBy | string | |
pageSize | integer (int32) | |
pageToken | string | |
requestId | string |
SELECT
examples
- get
- list
Gets details of a single ImageImport.
SELECT
name,
cloudStorageUri,
createTime,
diskImageTargetDefaults,
encryption,
machineImageTargetDefaults,
recentImageImportJobs
FROM google.vmmigration.image_imports
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND imageImportsId = '{{ imageImportsId }}' -- required;
Lists ImageImports in a given project.
SELECT
name,
cloudStorageUri,
createTime,
diskImageTargetDefaults,
encryption,
machineImageTargetDefaults,
recentImageImportJobs
FROM google.vmmigration.image_imports
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND filter = '{{ filter }}'
AND orderBy = '{{ orderBy }}';
INSERT
examples
- create
- Manifest
Creates a new ImageImport in a given project.
INSERT INTO google.vmmigration.image_imports (
data__cloudStorageUri,
data__diskImageTargetDefaults,
data__machineImageTargetDefaults,
data__encryption,
projectsId,
locationsId,
imageImportId,
requestId
)
SELECT
'{{ cloudStorageUri }}',
'{{ diskImageTargetDefaults }}',
'{{ machineImageTargetDefaults }}',
'{{ encryption }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ imageImportId }}',
'{{ requestId }}'
RETURNING
name,
done,
error,
metadata,
response
;
# Description fields are for documentation purposes
- name: image_imports
props:
- name: projectsId
value: string
description: Required parameter for the image_imports resource.
- name: locationsId
value: string
description: Required parameter for the image_imports resource.
- name: cloudStorageUri
value: string
description: >
Immutable. The path to the Cloud Storage file from which the image should be imported.
- name: diskImageTargetDefaults
value: object
description: >
Immutable. Target details for importing a disk image, will be used by ImageImportJob.
- name: machineImageTargetDefaults
value: object
description: >
Immutable. Target details for importing a machine image, will be used by ImageImportJob.
- name: encryption
value: object
description: >
Immutable. The encryption details used by the image import process during the image adaptation for Compute Engine.
- name: imageImportId
value: string
- name: requestId
value: string
DELETE
examples
- delete
Deletes a single ImageImport.
DELETE FROM google.vmmigration.image_imports
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND imageImportsId = '{{ imageImportsId }}' --required
AND requestId = '{{ requestId }}';