1Ravada(3)             User Contributed Perl Documentation            Ravada(3)
2
3
4

NAME

6       Ravada - Remove Virtual Desktop Manager
7

SYNOPSIS

9         use Ravada;
10
11         my $ravada = Ravada->new()
12
13   BUILD
14       Internal constructor
15
16   display_ip
17       Returns the default display IP read from the config file
18
19   nat_ip
20       Returns the IP for NATed environments
21
22   disconnect_vm
23       Disconnect all the Virtual Managers connections.
24
25   create_domain
26       Creates a new domain based on an ISO image or another domain.
27
28         my $domain = $ravada->create_domain(
29                name => $name
30           , id_iso => 1
31         );
32
33
34         my $domain = $ravada->create_domain(
35                name => $name
36           , id_base => 3
37         );
38
39   remove_domain
40       Removes a domain
41
42         $ravada->remove_domain($name);
43
44   search_domain
45         my $domain = $ravada->search_domain($name);
46
47   search_domain_by_id
48         my $domain = $ravada->search_domain_by_id($id);
49
50   list_vms
51       List all the Virtual Machine Managers
52
53   list_domains
54       List all created domains
55
56         my @list = $ravada->list_domains();
57
58       This list can be filtered:
59
60         my @active = $ravada->list_domains(active => 1);
61         my @inactive = $ravada->list_domains(active => 0);
62
63         my @user_domains = $ravada->list_domains(user => $id_user);
64
65         my @user_active = $ravada->list_domains(user => $id_user, active => 1);
66
67   list_domains_data
68       List all domains in raw format. Return a list of id => { name , id ,
69       is_active , is_base }
70
71          my @list = $ravada->list_domains_data();
72
73          $c->render(json => @list);
74
75   list_bases
76       List all base domains
77
78         my @list = $ravada->list_domains();
79
80   list_bases_data
81       List information about the bases
82
83   list_images
84       List all ISO images
85
86   list_images_data
87       List information about the images
88
89       sub _list_images_lxc {
90           my $self = shift;
91           my @domains;
92           my $sth = $CONNECTOR->dbh->prepare(
93               "SELECT * FROM lxc_templates ORDER BY name"
94           );
95           $sth->execute;
96           while (my $row = $sth->fetchrow_hashref) {
97               push @domains,($row);
98           }
99           $sth->finish;
100           return @domains; }
101
102       sub _list_images_data_lxc {
103           my $self = shift;
104           my @data;
105           for ($self->list_images_lxc ) {
106               push @data,{ id => $_->{id} , name => $_->{name} };
107           }
108           return \@data; }
109
110   remove_volume
111         $ravada->remove_volume($file);
112
113   clean_old_requests
114       Before processing requests, old requests must be cleaned.
115
116   process_requests
117       This is run in the ravada backend. It processes the commands requested
118       by the fronted
119
120         $ravada->process_requests();
121
122   process_long_requests
123       Process requests that take log time. It will fork on each one
124
125   process_all_requests
126       Process all the requests, long and short
127
128   list_vm_types
129       Returnsa list ofthe types of Virtual Machines available on this system
130
131   open_vm
132       Opens a VM of a given type
133
134         my $vm = $ravada->open_vm('KVM');
135
136   search_vm
137       Searches for a VM of a given type
138
139         my $vm = $ravada->search_vm('kvm');
140
141   import_domain
142       Imports a domain in Ravada
143
144           my $domain = $ravada->import_domain(
145                                   vm => 'KVM'
146                                   ,name => $name
147                                   ,user => $user_name
148                                   ,spinoff_disks => 1
149           );
150
151   version
152       Returns the version of the module
153

AUTHOR

155       Francesc Guasch-Ortiz    , frankie@telecos.upc.edu
156

SEE ALSO

158       Sys::Virt
159
160
161
162perl v5.30.0                      2019-08-08                         Ravada(3)
Impressum