1Rex::Virtualization::DoUcskeerr(C3o)ntributed Perl DocumReenxt:a:tViiorntualization::Docker(3)
2
3
4
6 Rex::Virtualization::Docker - Docker Virtualization Module
7
9 With this module you can manage Docker.
10
12 use Rex::Commands::Virtualization;
13
14 set virtualization => "Docker";
15
16 use Data::Dumper;
17
18 print Dumper vm list => "all";
19 print Dumper vm list => "running";
20
21 print Dumper vm info => "vm01";
22
23 vm destroy => "vm01";
24
25 vm delete => "vm01";
26
27 vm start => "vm01";
28
29 vm shutdown => "vm01";
30
31 vm reboot => "vm01";
32
33 # creating a vm
34 my $id = vm create => "vm01",
35 image => "ubuntu",
36 command => 'echo hello world',
37 memory => 512,
38 cpus => 1,
39 links => ['mysql:db'],
40 forward_port => [8080 => 80],
41 share_folder => ["hostdir" => "vmdir"],
42
43
44
45perl v5.38.0 2023-08-07 Rex::Virtualization::Docker(3)