ImageSource Class
Describes where the image used to create a container comes from.
public closed class ImageSource : IEquatable<ImageSource>- Implements
Constructors
| Name | Description |
|---|---|
| ImageSource() | |
| ImageSource(ImageSource) |
ImageSource overloads
ImageSource()
protected ImageSource()No documentation is available.
ImageSource(ImageSource)
ImageSource.csprotected ImageSource(ImageSource original)Parameters
originalImageSource
No documentation is available.
Methods
| Name | Description |
|---|---|
| Equals(ImageSource?) | |
| Equals(object?) | |
| FromArchive(string) | Creates an image source from a Docker image archive produced by docker save. |
| FromDockerfile(string, string?) | Creates an image source from a Dockerfile and build context directory. |
| FromDockerfile(string, string?, DockerfileBuildOptions?) | Creates an image source from a Dockerfile, a build context directory, and build options. |
| FromExisting(string) | Creates an image source from an image that already exists locally. |
| FromRegistry(string) | Creates an image source from a registry reference (for example redis:8). |
| GetHashCode() | |
| PrintMembers(StringBuilder) | |
| ToString() |
Equals overloads
Equals(ImageSource?)
public virtual bool Equals(ImageSource? other)No documentation is available.
Equals(object?)
FromArchive(string)
ImageSource.csCreates an image source from a Docker image archive produced by docker save.
public static ImageSource FromArchive(string archivePath)FromDockerfile overloads
FromDockerfile(string, string?)
ImageSource.csCreates an image source from a Dockerfile and build context directory.
public static ImageSource FromDockerfile(string dockerfilePath, string? contextDirectory = null)FromDockerfile(string, string?, DockerfileBuildOptions?)
ImageSource.csCreates an image source from a Dockerfile, a build context directory, and build options.
public static ImageSource FromDockerfile(string dockerfilePath, string? contextDirectory, DockerfileBuildOptions? options)Parameters
dockerfilePathstring- The path to the Dockerfile.
contextDirectorystring?- The build context directory. When
null, the directory of the Dockerfile. optionsDockerfileBuildOptions?- The build options, copied by this method. When
null, the default options.
Returns
FromExisting(string)
ImageSource.csCreates an image source from an image that already exists locally.
public static ImageSource FromExisting(string imageId)FromRegistry(string)
ImageSource.csCreates an image source from a registry reference (for example redis:8).
public static ImageSource FromRegistry(string name)GetHashCode()
PrintMembers(StringBuilder)
protected virtual bool PrintMembers(StringBuilder builder)No documentation is available.
ToString()
Operators
| Name | Description |
|---|---|
| operator ==(ImageSource?, ImageSource?) | |
| implicit operator ImageSource(string) | |
| operator !=(ImageSource?, ImageSource?) |
operator ==(ImageSource?, ImageSource?)
public static bool operator ==(ImageSource? left, ImageSource? right)No documentation is available.
implicit operator ImageSource(string)
ImageSource.cspublic static implicit operator ImageSource(string name)No documentation is available.
operator !=(ImageSource?, ImageSource?)
public static bool operator !=(ImageSource? left, ImageSource? right)No documentation is available.