Show / Hide Table of Contents

Class SecretPathVolumeOptions

Options for a Kubernetes SecretPath Volume.

Inheritance
object
SecretPathVolumeOptions
Implements
ISecretPathVolumeOptions
IEksVolumeOptions
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.Batch
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class SecretPathVolumeOptions : ISecretPathVolumeOptions, IEksVolumeOptions
Syntax (vb)
Public Class SecretPathVolumeOptions Implements ISecretPathVolumeOptions, IEksVolumeOptions
Remarks

See: https://kubernetes.io/docs/concepts/storage/volumes/#secret

ExampleMetadata: infused

Examples
EksJobDefinition jobDefn;

             jobDefn.Container.AddVolume(EksVolume.EmptyDir(new EmptyDirVolumeOptions {
                 Name = "emptyDir",
                 MountPath = "/Volumes/emptyDir"
             }));
             jobDefn.Container.AddVolume(EksVolume.HostPath(new HostPathVolumeOptions {
                 Name = "hostPath",
                 HostPath = "/sys",
                 MountPath = "/Volumes/hostPath"
             }));
             jobDefn.Container.AddVolume(EksVolume.Secret(new SecretPathVolumeOptions {
                 Name = "secret",
                 Optional = true,
                 MountPath = "/Volumes/secret",
                 SecretName = "mySecret"
             }));

Synopsis

Constructors

SecretPathVolumeOptions()

Options for a Kubernetes SecretPath Volume.

Properties

MountPath

The path on the container where the volume is mounted.

Name

The name of this volume.

Optional

Specifies whether the secret or the secret's keys must be defined.

Readonly

If specified, the container has readonly access to the volume.

SecretName

The name of the secret.

Constructors

SecretPathVolumeOptions()

Options for a Kubernetes SecretPath Volume.

public SecretPathVolumeOptions()
Remarks

See: https://kubernetes.io/docs/concepts/storage/volumes/#secret

ExampleMetadata: infused

Examples
EksJobDefinition jobDefn;

             jobDefn.Container.AddVolume(EksVolume.EmptyDir(new EmptyDirVolumeOptions {
                 Name = "emptyDir",
                 MountPath = "/Volumes/emptyDir"
             }));
             jobDefn.Container.AddVolume(EksVolume.HostPath(new HostPathVolumeOptions {
                 Name = "hostPath",
                 HostPath = "/sys",
                 MountPath = "/Volumes/hostPath"
             }));
             jobDefn.Container.AddVolume(EksVolume.Secret(new SecretPathVolumeOptions {
                 Name = "secret",
                 Optional = true,
                 MountPath = "/Volumes/secret",
                 SecretName = "mySecret"
             }));

Properties

MountPath

The path on the container where the volume is mounted.

public string? MountPath { get; set; }
Property Value

string

Remarks

Default: - the volume is not mounted

Name

The name of this volume.

public string Name { get; set; }
Property Value

string

Remarks

The name must be a valid DNS subdomain name.

See: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names

Optional

Specifies whether the secret or the secret's keys must be defined.

public bool? Optional { get; set; }
Property Value

bool?

Remarks

Default: true

Readonly

If specified, the container has readonly access to the volume.

public bool? Readonly { get; set; }
Property Value

bool?

Remarks

Otherwise, the container has read/write access.

Default: false

SecretName

The name of the secret.

public string SecretName { get; set; }
Property Value

string

Remarks

Must be a valid DNS subdomain name.

See: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names

Implements

ISecretPathVolumeOptions
IEksVolumeOptions
Back to top Generated by DocFX