Struct docker_compose::v2::VolumeMount [] [src]

pub struct VolumeMount {
    pub host: Option<HostVolume>,
    pub container: PathBuf,
    pub permissions: VolumePermissions,
    // some fields omitted
}

A volume associated with a service.

Fields

If this volume is external to the container, where should we find it?

Where should we mount this volume in the container? This must be an absolute path.

What should the permissions of this volume be in the container?

Methods

impl VolumeMount
[src]

Map a host path to a container path.

use docker_compose::v2 as dc;
dc::VolumeMount::host("./src", "/app");Run

Map a named volume to a container path.

use docker_compose::v2 as dc;
dc::VolumeMount::named("pgvolume", "/app");Run

An anonymous persistent volume which will remain associated with this service when it is recreated.

Trait Implementations

impl Eq for VolumeMount
[src]

impl PartialEq for VolumeMount
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Clone for VolumeMount
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Debug for VolumeMount
[src]

Formats the value using the given formatter.

impl Display for VolumeMount
[src]

Formats the value using the given formatter.

impl FromStr for VolumeMount
[src]

The associated error which can be returned from parsing.

Parses a string s to return a value of this type. Read more