this is the standard naming used in Debian/dpkg
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Acked-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Acked-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
to current one.
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Acked-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Acked-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
removes a warning during build
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Acked-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Acked-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
since the top-level Makefile is called during build now, where we might
no be in a git working tree.
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Acked-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Acked-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
found by building in a clean minimal chroot
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Acked-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Acked-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
we sometimes define
result => {}
on an api call, so check that result->{type} is defined
and guess the type if not
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
We can add to a bridge a non defined vlan interface.
We only need to check that physical interface exist
example:
auto eno1
iface eno1 inet manual
auto vmbr0
iface vmbr0 inet manual
bridge_ports eno1.1
[w.bumiller@proxmox.com: style & commit message fixup]
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
- special check for bond, set parent mtu from slaves mtu if no defined.
- error if parent mtu is lower than child mtu (not bigger)
- return if child mtu is not defined
- fix vlan check (parent/child was inverted)
when stopping a worker while doing a run_fork_with_timeout,
we want to handle that there and send the child the SIGTERM
so that it can clean up
for this we have to use readline_nointr,
because the read from the pipe gets interrupted by the signal
this partially fixes#1874
as we now correctly clean up the new disk, except if it is
on lvm/lvmthin (possibly other storages as well), and use the old disk
in the config
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
this is a wrapper to have an uninterruptible readline
so that we can read e.g. from a pipe even if interrupted by
a signal
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Usually, sub commands already form a logical group, so further grouping
just adds confusion (see 'qm' as example)
Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
This is useful if we do not have a fixed schema, for example to
print results from qemu agent commands.
Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
The value of $width depends on possible untainted $data (for example
task logs read from external files).
Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
Tools like pvesh and pveclient pass them as normal arguments. We use
a simply heuristic to test if there is an 'output_format' parameter.
If so, we remove all $standard_output_options and display [FORMAT_OPTIONS]
instead.
This simplifies usage, because we can simple omit the $terminal_opts
parameter in most cases (automatically call query_terminal_option) while
still setting $options.
Best shown with a example:
my $test_formatter = sub {
my ($res, $result_schema, $fmt_param) = @_;
PVE::CLIFormatter::print_api_result($res, $result_schema, undef, $fmt_param);
};
$cmddef = [ __PACKAGE__, 'test', [], undef, $test_formatter, $PVE::RESTHandler::standard_output_options],
- and rename format to 'output-format'
- provide a method to add properties to schema:
PVE::RESTHandler::add_standard_output_properties
- provide methods to extract output properties:
PVE::RESTHandler::extract_standard_output_properties()