Since external account binding is advertised the same way as the ToS,
it can be detected when creating an account and asked for if needed.
Signed-off-by: Folke Gleumes <f.gleumes@proxmox.com>
Reviewed-by: Fabian.Grünbichler <f.gruenbichler@proxmox.com>
Tested-by: Fabian.Grünbichler <f.gruenbichler@proxmox.com>
This should catch installations from our ISO on non-ZFS in uefi mode,
which won't get the updated grub efi binary installed upon upgrade,
because grub-pc is installed instead of grub-efi-amd64.
Adding this to pve7to8 should make this even more visible, than the
corresponding patch for promxox-kernel-helper (warnings printed during
regular package upgrades might be overlooked more easily than
a yellow line in the major upgrade checkscript)
The if/else order was chosen to limit the nesting level of the long
messages.
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
This allows to use `pvesh` on endpoints like /nodes/{node}/journal,
which return streamed (and possibly gzip'd) responses.
Currently, e.g. `pvesh get /nodes/localhost/journal --lastentries 10`
fails with:
gzip: stdout: Broken pipe
got hash object, but result schema specified array!
Using e.g. `--output-format yaml` resulted in:
---
download:
content-encoding: gzip
content-type: application/json
fh: &1 !!perl/ref
=: *1
stream: 1
gzip: stdout: Broken pipe
Failed to write
This is due the API call returning a "download" object (as seen above),
which contains (among some other things) a file handle to read the
response from.
With this patch, the response from such endpoints is now correctly read
and displayed. Only handles combinations of `Content-Encoding` == 'gzip'
and either 'text/plain' or 'application/json' for `Content-Type`.
This tries to mimic the behavior of the API server implementation when
encountering `download` objects.
Tested this with all four output formats 'text', 'json', 'json-pretty'
and 'yaml', as well as "cross-node" in a local test cluster.
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
For Fedora 38 the systemd shared object files used to check the systemd
version are located at /usr/lib64/systemd or /usr/lib/systemd.
Therefore, include /usr/lib64/systemd in the list of directories to
check.
Further, Fedora 38 adds a fc38 postfix to the filename, so expand the
regex to cover that as well.
Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
Commit 114e5f2c ("pve7to8: sync over from stable-7 branch")
accidentally got rid of the correct value 0 here and also the new TODO
message to improve the situation. But the TODO is actually easy,
because there already is the $upgraded variable. Just rely on that
instead of hard-coding and forgetting about it again.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
Displays a confirmation dialogue if the user didn't explicitly
provide a valid ceph version via the `--version` flag and if
stdout is connected to a tty.
Signed-off-by: Max Carrara <m.carrara@proxmox.com>
since the package won't get installed for systems upgraded from 7 to 8
we warn users who need systemd-boot - to be able to initialize new
ESPs - that they need to install it
The check for package installation is based on existance of the
changelog, since the package information used in pve7to8 comes from
the API-modules, which limit it to the pve-relevant packages.
tested in VMs with uefi and legacy mode, with existing
proxmox-boot-uuids both with and w/o systemd-boot being installed
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
It's required in the schema for notes-template and protected, but when
parsing vzdump.conf, it shouldn't matter whether the storage parameter
is set or not.
The warning is ugly and users might interpret it as something that
needs to be acted upon for the upgrade:
parse error in '/etc/vzdump.conf' - 'storage': missing property - 'notes-template' requires this property\nmissing property - 'protected' requires this property
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
(cherry picked from commit 517abd0cd2)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
It just talks about the default behavior since PVE 7. It's rather
confusing to mention this, because the behavior doesn't change anymore
in PVE 8.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
(cherry picked from commit b58348b1b6)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
The current inequality check for content-dirs does not correctly
handle the case in which `abs_path` returns undef. This can result in
confusing warnings:
storage [...] uses directory for multiple content types [...]
Fix this by skipping paths for which `abs_path` returns undef. This
matches the behavior of the actual content-dirs check in PVE 8 [0].
[0]: https://git.proxmox.com/?p=pve-storage.git;a=commit;h=09f1f847a
Fixes: ea0a4f1943
Signed-off-by: Friedrich Weber <f.weber@proxmox.com>
(cherry picked from commit 20fb9aa3f1)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
in pve-http-server the proxyto_callback always has a complete list of
parameters, not only the ones in the url, so adapt the implementation
here to do the same
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
To provide similar output on the CLI as is possible in the GUI/API
regaring OSD details.
By default (output-format=text) a more concise output is shown. Using
json or yaml as output format will print all the available data.
The 'verbose' flag causes json-pretty output to be used.
The functionality is split between the actual function and the output
formatter as not all options/parameters are available in each.
Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
With Proxmox VE 8, we'll have support for a enterprise ceph repo,
accessed through Proxmox VE subscriptions, to provide more broadly
tested ceph updates for production setups.
Replace the test-repository parameter with an actual enum of
selectable repo types for:
- test (same as previously selected through setting test-repository)
- no-subscription (the previous default, then named "main")
- enterprise (new and the default now, recommended for production)
Note that writing the auth-part is a bit hacky and might/should be
improved.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
squashed from the respective commits of the stable-7 branch, which is
the canonical source for this specific script.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
The API::Ceph::Pools module is deprecated. Use the new API::Ceph::Pool
(singular) module.
Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
Reviewed-by: Dominik Csapak <d.csapak@proxmox.com>
Tested-by: Dominik Csapak <d.csapak@proxmox.com>
Redirecting stdout is not a feasible approach, as that also affects
all run_commands and other command executions/forks done by the API
handler, and thus breaks parsing outputs of such command executions
in the API handlers.
We plan to add a `--result-fd` option instead, allowing users to pass
their own file, open FD or named pipe to the pvesh, so that they can
process the output in streaming or in full afterward afterwards.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
otherwise, print/warn statements by the API endpoint are included in the
output, which breaks JSON parsing in case of output-format == json*.
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Based to the suggestion of Wolfgang, in regard to `split_list()`,
I converted the `split_list()` to `split(/\0/, $param->{$key});`
this will split the `$param->{$key}` null characters and push each
element to the `$args` array along with the key value.
changes since v1:
* get rid of the `use PVE::Tools qw(split_list);` since not need it anymore.
* replace the split_list to split(/\0/).
Signed-off-by: Moayad Almalat <m.almalat@proxmox.com>
Commit d8cd8e8cf9 introduced a
regression where only stale replicated volumes with an older
timestamp would be cleaned up. This meant that after removing a volume
from the guest config, it would only be cleaned up the second time the
replication ran afterwards. And the volume could become completely
orphaned in case the relevant storage wasn't used by the job anymore.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
while dropping the instance where the local variable was unused.
prepare() was changed a while ago to return all local snapshots.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
when installing non-quincy versions, 'ceph-volume' is not contained in
the respective repositories and, thus, the install process would fail.
Signed-off-by: Stefan Sterz <s.sterz@proxmox.com>
[ T: reworded commit subject ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
storage_check_enabled() already dies with an appropriate error message
so we don't have to handle it here
Signed-off-by: Oguz Bektas <o.bektas@proxmox.com>