Skip to content

DockerImage

A Docker image.

Initializers

using AlibabaCloud.SDK.ROS.CDK.Core;
new DockerImage(string Image, string ImageHash = null);
Name Type Description
Image string No description.
ImageHash string No description.

ImageRequired

  • Type: string

ImageHashOptional

  • Type: string

Methods

Name Description
Cp Copies a file or directory out of the Docker image to the local filesystem.
Run Runs a Docker image.
ToJSON Provides a stable representation of this image for JSON serialization.

Cp

private string Cp(string ImagePath, string OutputPath = null)

Copies a file or directory out of the Docker image to the local filesystem.

If outputPath is omitted the destination path is a temporary directory.

ImagePathRequired

  • Type: string

the path in the Docker image.


OutputPathOptional

  • Type: string

the destination path for the copy operation.


Run

private void Run(DockerRunOptions Options = null)

Runs a Docker image.

OptionsOptional


ToJSON

private string ToJSON()

Provides a stable representation of this image for JSON serialization.

Static Functions

Name Description
FromBuild Builds a Docker image.
FromRegistry Reference an image on DockerHub or another online registry.

FromBuild

using AlibabaCloud.SDK.ROS.CDK.Core;
DockerImage.FromBuild(string Path, DockerBuildOptions Options = null);

Builds a Docker image.

PathRequired

  • Type: string

The path to the directory containing the Docker file.


OptionsOptional

Docker build options.


FromRegistry

using AlibabaCloud.SDK.ROS.CDK.Core;
DockerImage.FromRegistry(string Image);

Reference an image on DockerHub or another online registry.

ImageRequired

  • Type: string

the image name.


Properties

Name Type Description
Image string No description.

ImageRequired

public string Image { get; }
  • Type: string