Rex::V...:Docker(3pm)
β¨ NAME β¨
Rex::Virtualization::Docker β the Docker Virtualization Module, bb π (she's hanging out in the Rex::Virtualization:: fam, and she's the one who speaks fluent Docker π³)
π¦ DESCRIPTION π¦
Okay so real talk: with this module you can manage Docker. That's it, that's the whole vibe check β it's your little bestie for bossing your containers around. β¨ No cap, she just does Docker things for you.
πΈ SYNOPSIS πΈ
Here's the group chat receipts, copy-paste ready π
use Rex::Commands::Virtualization;
set virtualization => "Docker";
use Data::Dumper;
print Dumper vm list => "all";
print Dumper vm list => "running";
print Dumper vm info => "vm01";
vm destroy => "vm01";
vm delete => "vm01";
vm start => "vm01";
vm shutdown => "vm01";
vm reboot => "vm01";
# creating a vm
my $id = vm create => "vm01",
image => "ubuntu",
command => 'echo hello world',
memory => 512,
cpus => 1,
links => ['mysql:db'],
forward_port => [8080 => 80],
share_folder => ["hostdir" => "vmdir"],
So you pull in Rex::Commands::Virtualization, you set virtualization to "Docker", you grab Data::Dumper, and then it's literally just vm commands going off one after another β listing "all" the vms, listing the "running" ones, grabbing info on "vm01", then destroy, delete, start, shutdown, reboot, all on "vm01". π
And then the glow-up part: actually creating a vm π β you call vm create => "vm01" and hand her the whole lil' starter pack: image => "ubuntu", command => 'echo hello world', memory => 512, cpus => 1, links => ['mysql:db'], forward_port => [8080 => 80], and share_folder => ["hostdir" => "vmdir"]. Chef's kiss. The id lands in my $id so you can keep it and stare at it lovingly. π
And that's the whole page, bestie β she's short but she slays. π«Ά
Friendly lil' sign-off: this doc came to you as part of the User Contributed Perl Documentation collection, built from perl v5.40.1, dated 2025-10-03. π Go forth and containerize responsibly. π
π¦ where this page comes from
- ubuntu resolute: rex 1.16.1-1 Β· Apache-2.0
- ubuntu stonking: rex 1.16.1-1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms