public static final class CreateImageRequest.Builder extends Object
限定符和类型 | 方法和说明 |
---|---|
CreateImageRequest.Builder |
architecture(String architecture)
The system architecture of the system disk.
|
CreateImageRequest.Builder |
bootMode(String bootMode)
The boot mode of the custom image.
|
CreateImageRequest |
build() |
CreateImageRequest.Builder |
clientToken(String clientToken)
The client token that is used to ensure the idempotence of the request.
|
CreateImageRequest.Builder |
description(String description)
The description of the custom image.
|
CreateImageRequest.Builder |
detectionStrategy(String detectionStrategy)
The mode that you want to use to check the source image.
|
CreateImageRequest.Builder |
diskDeviceMapping(List<CreateImageRequest.DiskDeviceMapping> diskDeviceMapping)
The information about the custom image.
|
CreateImageRequest.Builder |
imageFamily(String imageFamily)
The name of the family of the custom image.
|
CreateImageRequest.Builder |
imageName(String imageName)
The name of the custom image.
|
CreateImageRequest.Builder |
imageVersion(String imageVersion)
The version of the custom image.
|
CreateImageRequest.Builder |
instanceId(String instanceId)
The ID of the instance that is used to create the custom image.
|
CreateImageRequest.Builder |
ownerAccount(String ownerAccount)
OwnerAccount.
|
CreateImageRequest.Builder |
ownerId(Long ownerId)
OwnerId.
|
CreateImageRequest.Builder |
platform(String platform)
The distribution of the operating system for the system disk in the custom image.
|
CreateImageRequest.Builder |
regionId(String regionId)
The region ID of the custom image that you want to create.
|
CreateImageRequest.Builder |
resourceGroupId(String resourceGroupId)
The ID of the resource group to which you want to assign the custom image.
|
CreateImageRequest.Builder |
resourceOwnerAccount(String resourceOwnerAccount)
ResourceOwnerAccount.
|
CreateImageRequest.Builder |
resourceOwnerId(Long resourceOwnerId)
ResourceOwnerId.
|
CreateImageRequest.Builder |
snapshotId(String snapshotId)
The ID of the snapshot that is used to create the custom image.
|
CreateImageRequest.Builder |
sourceRegionId(String sourceRegionId)
SourceRegionId.
|
CreateImageRequest.Builder |
tag(List<CreateImageRequest.Tag> tag)
The tags that you want to add to the custom image.
|
public CreateImageRequest.Builder sourceRegionId(String sourceRegionId)
public CreateImageRequest.Builder architecture(String architecture)
* i386 * x86\_64 * arm64 Default value: x86\_64.
public CreateImageRequest.Builder bootMode(String bootMode)
* BIOS * UEFI > You must be familiar with the boot modes that are supported by the specified image. When you use this parameter to change the boot mode of the image, specify a boot mode that is supported by the image to ensure that instances that use this image can start as expected.
public CreateImageRequest.Builder clientToken(String clientToken)
public CreateImageRequest.Builder description(String description)
public CreateImageRequest.Builder detectionStrategy(String detectionStrategy)
The following items are checked in standard check mode: * Virtio: whether the virtio driver is installed. * Fstab: whether the mounting configurations in the fstab file are valid. * Grub: whether the GRand Unified Bootloader (GRUB) configurations are valid. * SystemImage: whether the image is valid. Do not import images that are in the ISO format or empty. * CloudInit: whether cloud-init is installed. * NVMe: whether the NVMe driver is installed. * Selinux: whether SElinux is enabled. * OnlineResizeFS: whether the root partition can be automatically resized. * Dhcp: whether Dynamic Host Configuration Protocol (DHCP) is enabled for network interfaces. * RtcTimeMode: the RTC time mode. * Platform: the platform. Example: Linux or Windows. * OSVersion: the operating system version. Example: Centos 7.9. * Architecture: the architecture. Example: ARM or x86\_64. * BootMode: the boot mode. Example: UEFI or Legacy. * KernelVersion: the kernel version. * CloudAssistant: whether the Cloud Assistant client is installed. * SecurityCenterAgent: whether the Security Center agent is installed.
public CreateImageRequest.Builder diskDeviceMapping(List<CreateImageRequest.DiskDeviceMapping> diskDeviceMapping)
public CreateImageRequest.Builder imageFamily(String imageFamily)
public CreateImageRequest.Builder imageName(String imageName)
public CreateImageRequest.Builder imageVersion(String imageVersion)
> If you specify an instance by using the `InstanceId` parameter and the instance uses an Alibaba Cloud Marketplace image or a custom image that is created from an Alibaba Cloud Marketplace image, you must leave this parameter empty or set this parameter to the value of the ImageVersion parameter of the instance.
public CreateImageRequest.Builder instanceId(String instanceId)
public CreateImageRequest.Builder ownerAccount(String ownerAccount)
public CreateImageRequest.Builder ownerId(Long ownerId)
public CreateImageRequest.Builder platform(String platform)
* CentOS * Ubuntu * SUSE * OpenSUSE * RedHat * Debian * CoreOS * Aliyun * Windows Server 2012 * Windows 7 * Customized Linux * Others Linux Default value: Others Linux.
public CreateImageRequest.Builder regionId(String regionId)
public CreateImageRequest.Builder resourceGroupId(String resourceGroupId)
> If you call the CreateImage operation as a RAM user who is not authorized to manage the default resource group and you do not specify the `ResourceGroupId` parameter, the `Forbidden: User not authorized to operate on the specified resource` error message is returned. You must specify the ID of a resource group that the RAM user is authorized to manage or authorize the RAM user to manage the default resource group before you call the CreateImage operation again.
public CreateImageRequest.Builder resourceOwnerAccount(String resourceOwnerAccount)
public CreateImageRequest.Builder resourceOwnerId(Long resourceOwnerId)
public CreateImageRequest.Builder snapshotId(String snapshotId)
public CreateImageRequest.Builder tag(List<CreateImageRequest.Tag> tag)
public CreateImageRequest build()
Copyright © 2023. All rights reserved.