Class: DockerEngineAPI::Models::Volume::ClusterVolume::Spec::AccessMode

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/docker_engine_api/models/volume.rb

Overview

See Also:

Defined Under Namespace

Modules: Availability, Scope, Sharing Classes: AccessibilityRequirements, CapacityRange, Secret

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(key: nil, secret: nil) ⇒ Object

Some parameter documentations has been truncated, see Secret for more details.

One cluster volume secret entry. Defines a key-value pair that is passed to the plugin.

Parameters:

  • key (String) (defaults to: nil)

    Key is the name of the key of the key-value pair passed to

  • secret (String) (defaults to: nil)

    Secret is the swarm Secret object from which to read data.



# File 'lib/docker_engine_api/models/volume.rb', line 427


Instance Attribute Details

#accessibility_requirementsDockerEngineAPI::Models::Volume::ClusterVolume::Spec::AccessMode::AccessibilityRequirements?

Requirements for the accessible topology of the volume. These fields are optional. For an in-depth description of what these fields mean, see the CSI specification.



345
346
347
348
349
# File 'lib/docker_engine_api/models/volume.rb', line 345

optional :accessibility_requirements,
-> {
  DockerEngineAPI::Volume::ClusterVolume::Spec::AccessMode::AccessibilityRequirements
},
api_name: :AccessibilityRequirements

#availabilitySymbol, ...

The availability of the volume for use in tasks.

  • active The volume is fully available for scheduling on the cluster

  • pause No new workloads should use the volume, but existing workloads are not stopped.

  • drain All workloads using this volume should be stopped and rescheduled, and no new ones should be started.



361
362
363
# File 'lib/docker_engine_api/models/volume.rb', line 361

optional :availability,
enum: -> { DockerEngineAPI::Volume::ClusterVolume::Spec::AccessMode::Availability },
api_name: :Availability

#capacity_rangeDockerEngineAPI::Models::Volume::ClusterVolume::Spec::AccessMode::CapacityRange?

The desired capacity that the volume should be created with. If empty, the plugin will decide the capacity.



370
371
372
# File 'lib/docker_engine_api/models/volume.rb', line 370

optional :capacity_range,
-> { DockerEngineAPI::Volume::ClusterVolume::Spec::AccessMode::CapacityRange },
api_name: :CapacityRange

#mount_volumeObject?

Options for using this volume as a Mount-type volume.

Either MountVolume or BlockVolume, but not both, must be
present.

properties: FsType: type: “string” description: | Specifies the filesystem type for the mount volume. Optional. MountFlags: type: “array” description: | Flags to pass when mounting the volume. Optional. items: type: “string” BlockVolume: type: “object” description: | Options for using this volume as a Block-type volume. Intentionally empty.

Returns:

  • (Object, nil)


387
# File 'lib/docker_engine_api/models/volume.rb', line 387

optional :mount_volume, DockerEngineAPI::Internal::Type::Unknown, api_name: :MountVolume

#scopeSymbol, ...

The set of nodes this volume can be used on at one time.

  • single The volume may only be scheduled to one node at a time.

  • multi the volume may be scheduled to any supported number of nodes at a time.



397
398
399
# File 'lib/docker_engine_api/models/volume.rb', line 397

optional :scope,
enum: -> { DockerEngineAPI::Volume::ClusterVolume::Spec::AccessMode::Scope },
api_name: :Scope

#secretsArray<DockerEngineAPI::Models::Volume::ClusterVolume::Spec::AccessMode::Secret>?

Swarm Secrets that are passed to the CSI storage plugin when operating on this volume.



406
407
408
409
410
# File 'lib/docker_engine_api/models/volume.rb', line 406

optional :secrets,
-> {
  DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Volume::ClusterVolume::Spec::AccessMode::Secret]
},
api_name: :Secrets

#sharingSymbol, ...

The number and way that different tasks can use this volume at one time.

  • none The volume may only be used by one task at a time.

  • readonly The volume may be used by any number of tasks, but they all must mount the volume as readonly

  • onewriter The volume may be used by any number of tasks, but only one may mount it as read/write.

  • all The volume may have any number of readers and writers.



423
424
425
# File 'lib/docker_engine_api/models/volume.rb', line 423

optional :sharing,
enum: -> { DockerEngineAPI::Volume::ClusterVolume::Spec::AccessMode::Sharing },
api_name: :Sharing

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/docker_engine_api/models/volume.rb', line 497