Table of Contents

Class DockerVolume

Namespace
Amazon.CDK
Assembly
Amazon.CDK.dll

A Docker volume.

public class DockerVolume : IDockerVolume
Inheritance
DockerVolume
Implements
Inherited Members

Examples

// The code below shows an example of how to instantiate this type.
            // The values are placeholders you should change.
            using Amazon.CDK;
            var dockerVolume = new DockerVolume {
                ContainerPath = "containerPath",
                HostPath = "hostPath",

                // the properties below are optional
                Consistency = DockerVolumeConsistency.CONSISTENT
            };

Remarks

ExampleMetadata: fixture=_generated

Constructors

DockerVolume()

public DockerVolume()

Properties

Consistency

Mount consistency.

public DockerVolumeConsistency? Consistency { get; set; }

Property Value

DockerVolumeConsistency?

Remarks

Only applicable for macOS

Default: DockerConsistency.DELEGATED

See: https://docs.docker.com/storage/bind-mounts/#configure-mount-consistency-for-macos

ContainerPath

The path where the file or directory is mounted in the container.

public string ContainerPath { get; set; }

Property Value

string

HostPath

The path to the file or directory on the host machine.

public string HostPath { get; set; }

Property Value

string