Interface IDockerVolumeConfiguration
The configuration for a Docker volume.
Namespace: Amazon.CDK.AWS.ECS
Assembly: Amazon.CDK.AWS.ECS.dll
Syntax (csharp)
public interface IDockerVolumeConfiguration
Syntax (vb)
Public Interface IDockerVolumeConfiguration
Remarks
Docker volumes are only supported when you are using the EC2 launch type.
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.ECS;
var dockerVolumeConfiguration = new DockerVolumeConfiguration {
Driver = "driver",
Scope = Scope.TASK,
// the properties below are optional
Autoprovision = false,
DriverOpts = new Dictionary<string, string> {
{ "driverOptsKey", "driverOpts" }
},
Labels = new Dictionary<string, string> {
{ "labelsKey", "labels" }
}
};
Synopsis
Properties
Autoprovision | Specifies whether the Docker volume should be created if it does not already exist. |
Driver | The Docker volume driver to use. |
DriverOpts | A map of Docker driver-specific options passed through. |
Labels | Custom metadata to add to your Docker volume. |
Scope | The scope for the Docker volume that determines its lifecycle. |
Properties
Autoprovision
Specifies whether the Docker volume should be created if it does not already exist.
virtual Nullable<bool> Autoprovision { get; }
Property Value
System.Nullable<System.Boolean>
Remarks
If true is specified, the Docker volume will be created for you.
Default: false
Driver
The Docker volume driver to use.
string Driver { get; }
Property Value
System.String
DriverOpts
A map of Docker driver-specific options passed through.
virtual IDictionary<string, string> DriverOpts { get; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.String>
Remarks
Default: No options
Labels
Custom metadata to add to your Docker volume.
virtual IDictionary<string, string> Labels { get; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.String>
Remarks
Default: No labels
Scope
The scope for the Docker volume that determines its lifecycle.
Scope Scope { get; }
Property Value