use-docker-volume 0.0.1

Primitive Docker volume and mount syntax helpers for RustUse
Documentation
  • Coverage
  • 100%
    19 out of 19 items documented1 out of 11 items with examples
  • Size
  • Source code size: 8.91 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 596.16 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 4s Average build duration of successful builds.
  • all releases: 4s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • RustUse/use-docker
    1 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • CloudBranch

use-docker-volume

Primitive Docker volume and mount syntax helpers for RustUse.

This crate parses and renders named volumes, bind mounts, anonymous volumes, and read-only flags. It keeps behavior simple and does not inspect the filesystem.

Basic Usage

use use_docker_volume::{DockerVolumeMount, MountAccess, VolumeKind};

let mount: DockerVolumeMount = "cache:/var/cache:ro".parse()?;

assert_eq!(mount.kind(), VolumeKind::Named);
assert_eq!(mount.access(), MountAccess::ReadOnly);
assert_eq!(mount.target(), "/var/cache");
# Ok::<(), Box<dyn std::error::Error>>(())