export_image
async
¶
export_image(
*,
config_overrides: Optional[AsyncEC2ClientConfig] = None,
client_token: Optional[String] = None,
description: Optional[String] = None,
disk_image_format: Optional[DiskImageFormat] = None,
dry_run: Optional[Boolean] = None,
image_id: Optional[ImageId] = None,
s3_export_location: Optional[ExportTaskS3LocationRequest] = None,
role_name: Optional[String] = None,
tag_specifications: Optional[TagSpecificationList] = None,
) -> ExportImageResult
Exports an Amazon Machine Image (AMI) to a VM file. For more information, see Exporting a VM directly from an Amazon Machine Image (AMI) in the VM Import/Export User Guide.
Parameters:
-
client_token(Optional[String], default:None) –Token to enable idempotency for export image requests.
-
description(Optional[String], default:None) –A description of the image being exported. The maximum length is 255 characters.
-
disk_image_format(Optional[DiskImageFormat], default:None) –The disk image format.
-
dry_run(Optional[Boolean], default:None) –Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is
DryRunOperation. Otherwise, it isUnauthorizedOperation. -
image_id(Optional[ImageId], default:None) –The ID of the image.
-
s3_export_location(Optional[ExportTaskS3LocationRequest], default:None) –The Amazon S3 bucket for the destination image. The destination bucket must exist.
-
role_name(Optional[String], default:None) –The name of the role that grants VM Import/Export permission to export images to your Amazon S3 bucket. If this parameter is not specified, the default role is named 'vmimport'.
-
tag_specifications(Optional[TagSpecificationList], default:None) –The tags to apply to the export image task during creation.
Raises:
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_ec2/_services/async_ec2.py
42791 42792 42793 42794 42795 42796 42797 42798 42799 42800 42801 42802 42803 42804 42805 42806 42807 42808 42809 42810 42811 42812 42813 42814 42815 42816 42817 42818 42819 42820 42821 42822 42823 42824 42825 42826 42827 42828 42829 42830 42831 42832 42833 42834 42835 42836 42837 42838 42839 42840 42841 42842 42843 42844 42845 42846 42847 42848 42849 42850 42851 42852 42853 42854 42855 42856 42857 42858 42859 42860 42861 42862 42863 42864 42865 42866 42867 42868 42869 | |