ImageExportArgs

data class ImageExportArgs(val imageId: Output<String>? = null, val ossBucket: Output<String>? = null, val ossPrefix: Output<String>? = null) : ConvertibleToJava<ImageExportArgs>

Export a custom image to the OSS bucket in the same region as the custom image.

NOTE: If you create an ECS instance using a mirror image and create a system disk snapshot again, exporting a custom image created from the system disk snapshot is not supported. NOTE: Support for exporting custom images that include data disk snapshot information in the image. The number of data disks cannot exceed 4 and the maximum capacity of a single data disk cannot exceed 500 GiB. NOTE: Before exporting the image, you must authorize the cloud server ECS official service account to write OSS permissions through RAM. NOTE: Available in 1.68.0+.

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.ecs.ImageExport;
import com.pulumi.alicloud.ecs.ImageExportArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var default_ = new ImageExport("default", ImageExportArgs.builder()
.imageId("m-bp1gxy***")
.ossBucket("ecsimageexportconfig")
.ossPrefix("ecsExport")
.build());
}
}

Attributes Reference0

The following attributes are exported:

  • id - ID of the image.

Constructors

Link copied to clipboard
fun ImageExportArgs(imageId: Output<String>? = null, ossBucket: Output<String>? = null, ossPrefix: Output<String>? = null)

Functions

Link copied to clipboard
open override fun toJava(): ImageExportArgs

Properties

Link copied to clipboard
val imageId: Output<String>? = null

The source image ID.

Link copied to clipboard
val ossBucket: Output<String>? = null

Save the exported OSS bucket.

Link copied to clipboard
val ossPrefix: Output<String>? = null

The prefix of your OSS Object. It can be composed of numbers or letters, and the character length is 1 ~ 30.