=> 'test1',
body => {
action => "start",
force => JSON::false,
stateful => JSON::false,
timeout => 30,
} )->get;
em *
a Perl HASH ref which reflects the JSON data sent from the LXD server. Note, that Booleans have to
be treated special, by using C<JSON::false> and C<JSON::true>. Otherwise, they follow B<exactly
y => {
action => "start",
force => JSON::false,
stateful => JSON::false,
timeout => 30,
} );
That HASH ref also follows the
package lxd::instance;
use strict;
use warnings;
use JSON;
use Data::Dumper;
sub state {
my ($elf, $lxd, %params) = @_;
my $wait = delete $params{wait} // 1;
my $f = $lxd->instance_stat
ction {
my ($elf, $lxd, $action, %params) = @_;
$params{stateful} //= JSON::false;
$params{force} //= JSON::false;
$params{timeout} //= 30;
my $wait = delete $params{wait} // 1
Data::Dumper;
$Data::Dumper::Indent = 1;
our $VERSION = '0.03';
use Encode qw(encode_utf8);
use JSON;
use HTTP::Status qw(:constants);
use Moose;
use Log::Log4perl qw(:easy);
Log::Log4perl->easy_