delonix volumes
Volumes nomeados e bind mounts: create, ls, inspect, rm, apply.
Named volumes and bind mounts: create, ls, inspect, rm, apply.
Wrapper fino sobre o VolumeStore. No container run,
-v nome:/destino[:ro] resolve para um volume nomeado (criado on-demand) e
-v /host:/destino[:ro] para um bind mount — a distinção é automática.
A thin wrapper over VolumeStore. In container run,
-v name:/dest[:ro] resolves to a named volume (created on demand) and
-v /host:/dest[:ro] to a bind mount — the distinction is automatic.
📄 Implementação real em Rust: cmd/volume.rs
Usage: dlx volumes [OPTIONS] <COMMAND>
Commands:
create Create a named volume
ls List the volumes
inspect Details of a volume (includes real on-disk usage)
describe Readable detail of one or more volumes, `kubectl describe` style (for humans; use `inspect` for the usual compact view)
rm Remove a volume. Refuses while a container or a `kind: ShareVolume` still references it (use `--force` to remove it anyway)
apply Apply the `kind: Volume` documents from a manifest (idempotent by name)
snapshot Point-in-time snapshots of a volume (tar.gz under the volume; safe in rootless)
help Print this message or the help of the given subcommand(s)
Options:
--l18n <en|pt> Output language: `en` (default) or `pt` (Portuguese, pt_AO). Also settable via `$DELONIX_L18N`. Global — works before any subcommand
-h, --help Print helpvolumes snapshot
Point-in-time snapshots of a volume (tar.gz under the volume; safe in rootless)
Usage: dlx volumes snapshot [OPTIONS] <COMMAND>
Commands:
create Create a snapshot NOW (default name: UTC timestamp)
ls List the snapshots of a volume
restore Restore a snapshot INTO the volume (replaces the current data — stop the consumers first)
rm Delete a snapshot
help Print this message or the help of the given subcommand(s)
Options:
--l18n <en|pt> Output language: `en` (default) or `pt` (Portuguese, pt_AO). Also settable via `$DELONIX_L18N`. Global — works before any subcommand
-h, --help Print helpExemplos
delonix volumes snapshot create dados antes-da-migracao
delonix volumes snapshot ls dadosvolumes describe
Readable detail of one or more volumes, kubectl describe style (for humans; use inspect for the usual compact view)
Usage: dlx volumes describe [OPTIONS] <NAMES>...
Arguments:
<NAMES>...
Options:
--l18n <en|pt> Output language: `en` (default) or `pt` (Portuguese, pt_AO). Also settable via `$DELONIX_L18N`. Global — works before any subcommand
-h, --help Print helpExemplos
delonix volumes describe dadosvolumes create
Create a named volume
Usage: dlx volumes create [OPTIONS] <NAME>
Arguments:
<NAME>
Options:
--driver <DRIVER> `local` (default) or `nfs` [default: local]
--l18n <en|pt> Output language: `en` (default) or `pt` (Portuguese, pt_AO). Also settable via `$DELONIX_L18N`. Global — works before any subcommand
--device <DEVICE> Device/export (`nfs` driver)
--options <OPTIONS> Additional mount options (`nfs` driver)
--quota <QUOTA> Quota (e.g. `2g`) — only applied if `--quota` is given
-h, --help Print helpExemplos
delonix volumes create dados --quota 10Gvolumes ls
List the volumes
Usage: dlx volumes ls [OPTIONS]
Options:
--l18n <en|pt> Output language: `en` (default) or `pt` (Portuguese, pt_AO). Also settable via `$DELONIX_L18N`. Global — works before any subcommand
-o, --output <OUTPUT> Output format: `table` (default) or `json` (ADR-0005) [default: table] [possible values: table, json]
-h, --help Print helpExemplos
delonix volumes lsvolumes inspect
Details of a volume (includes real on-disk usage)
Usage: dlx volumes inspect [OPTIONS] <NAME>
Arguments:
<NAME>
Options:
--l18n <en|pt> Output language: `en` (default) or `pt` (Portuguese, pt_AO). Also settable via `$DELONIX_L18N`. Global — works before any subcommand
-h, --help Print helpExemplos
delonix volumes inspect dadosvolumes rm
Remove a volume. Refuses while a container or a kind: ShareVolume still references it (use --force to remove it anyway)
Usage: dlx volumes rm [OPTIONS] <NAME>
Arguments:
<NAME>
Options:
-f, --force Remove it even with live references — DESTROYS the data of whatever is still using it
--l18n <en|pt> Output language: `en` (default) or `pt` (Portuguese, pt_AO). Also settable via `$DELONIX_L18N`. Global — works before any subcommand
-h, --help Print helpExemplos
delonix volumes rm dadosvolumes apply
Apply the kind: Volume documents from a manifest (idempotent by name)
Usage: dlx volumes apply [OPTIONS]
Options:
-f, --file <FILE>
--l18n <en|pt> Output language: `en` (default) or `pt` (Portuguese, pt_AO). Also settable via `$DELONIX_L18N`. Global — works before any subcommand
-h, --help Print helpExemplos
delonix volumes apply -f delonix-manifest.yamlLaboratórioLab
Prova que um volume nomeado sobrevive a um restart do container — ao contrário de escrever directamente no rootfs.
delonix volumes create dados
delonix container run -d --name db -v dados:/var/lib/data alpine sleep infinity
delonix container exec db sh -c 'echo ok > /var/lib/data/marca'
delonix container stop db && delonix container start db
delonix container exec db cat /var/lib/data/marcaProve a named volume survives a container restart — unlike writing straight to the rootfs.
delonix volumes create data
delonix container run -d --name db -v data:/var/lib/data alpine sleep infinity
delonix container exec db sh -c 'echo ok > /var/lib/data/mark'
delonix container stop db && delonix container start db
delonix container exec db cat /var/lib/data/markDesafioChallenge
Tira um snapshot do volume dados depois
de escrever nele, e usa volumes describe para veres o histórico de snapshots.
Take a snapshot of the data volume after
writing to it, and use volumes describe to see the snapshot history.