Commit Graph

5857 Commits

Author SHA1 Message Date
Stoiko Ivanov
9f5f981914 pve6to7: check for containers not supporting pure cgroupv2
Helpers copied from pve-container to avoid versioned bumps.

Early returns when no containers are running, or the containers don't
use systemd, as well as returning after finding the first affected
container to minimize impact and resource usage.

Checking running containers first since following /proc/<pid>/root is
cheaper than mounting all volumes for a container

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2021-07-05 17:06:43 +02:00
Thomas Lamprecht
410ae2a520 d/control: bump versioned build-dependency for pve-doc-generator
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 16:55:33 +02:00
Thomas Lamprecht
069bcbd2e7 ui: notes edit: set markdown basic as onlineHelp
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 15:35:46 +02:00
Thomas Lamprecht
1a89220277 ui: node status: prioritize non-production and fix ok case
Non-production repositories will always pull in their newer software,
so even if enterprise+subscription is OK we should mark it with
priority if, e.g., pvetest is enabled.

There was also a bug regarding the all OK state

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 15:33:45 +02:00
Thomas Lamprecht
72931fec68 ui: node status: rework repo status texts/icon
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 14:47:17 +02:00
Fabian Grünbichler
e5ae0f9e35 d/control: add missing (b-)depends on pve-rs
needed for the APT repo functionality

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
2021-07-05 13:10:11 +02:00
Thomas Lamprecht
30179cc0d7 ui: dc/guests: set line-height again and increase font-size
the 14px over 13px is not much, but as that is the font-size intended
for font-awesome it makes it all look nicer together

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 12:58:50 +02:00
Thomas Lamprecht
f9a7d55d14 ui: dc/guests: avoid using <br> for layouting
use a flex box with centered columns instead, that needs adding a div
per row, but that's IMO actually making it more clear what a row is
anyway.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 12:58:47 +02:00
Thomas Lamprecht
6b30714119 ui: dc/Guests: make update lazy
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 12:20:13 +02:00
Thomas Lamprecht
3e32628c22 ui: dc/Guests: fix indentation
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 12:20:13 +02:00
Stefan Reiter
d4c6f35c38 ui: dc/guests: remove 'line-height' from default style
Firefox doesn't correctly break to the next line if the line-height
is set as is (with certain fonts, including the default on debian it
seems). Simply remove it, as it isn't necessary.

Suggested-by: Dominik Csapak <d.csapak@proxmox.com>
Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
2021-07-05 12:19:40 +02:00
Fabian Ebner
08e22c1eac pveceph: also install nvme-cli
The nvme-cli package is recommended by (our) Ceph packages, but here
--no-install-recommends is used to avoid pulling in too much.

The issue with not installing nvme-cli is that a "security
information" mail notification is triggered by sudo each time Ceph
tries to get the device health metrics. While there is a sudoers
rule for /usr/sbin/nvme, Ceph uses 'sudo nvme ...', so it does not
apply when the package is not installed.

This didn't seem to happen with sudo in buster.

It's about 1 MiB of additional packages (nvme-cli + uuid-runtime).

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2021-07-05 12:05:13 +02:00
Thomas Lamprecht
e5457c1eb8 ui: node summary: slightly increase panles height
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 10:58:57 +02:00
Thomas Lamprecht
e4d3f62656 ui: status: improve reuse of gettext
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 10:47:58 +02:00
Thomas Lamprecht
cfc9f9600d ui: fix yet another bogus broken gettext usage
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 10:24:43 +02:00
Thomas Lamprecht
dab34bb5f5 ui: notes: add empty text with a hint that markdown is supported
We can do so unconditionally as this is a PVE specific component and
only used for guests and nodes, both using the markdown Parser.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-05 08:29:29 +02:00
Thomas Lamprecht
2f79184cc0 ui: node status: small code size reduction
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-04 22:09:36 +02:00
Thomas Lamprecht
4b832488aa ui: node/status view: padding-reduce fixup
overlooked the inline one, and that caused some layout troubles

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-04 22:09:17 +02:00
Thomas Lamprecht
98f73c48d2 ui: node/status view: reduce quite generous paddings
As both, the whole panels body and the actual items all had their own
padding it added up quite a bit.

Some padding is good to avoid elements being "glued" to the parent
borders, but that can be done with also with ~15 px vs. 30 px on each
side, so no need to waste that much extra space we can use in some
languages to render content

Added benefit, the status panel now is more in sync with the RRD
panels regarding content start/end.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-04 21:52:05 +02:00
Thomas Lamprecht
bcfcf87bf9 ui: node summary: rework repo status output
the icon on the left side look a bit weird here, as the lines
directly above had none and the actual status which the icon tried to
emphasize is on the right anyway.

Rework also the output.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-04 21:18:43 +02:00
Thomas Lamprecht
e950ab260d ui: node summary: followup code cleanup
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-04 21:17:35 +02:00
Fabian Ebner
2bb75d1ea3 ui: node summary: show repository configuration status
I tried to use itemid and lookupreference for the nodeStatus item, but couldn't
get it to work, so I factored it out.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2021-07-04 20:58:33 +02:00
Thomas Lamprecht
916e739f2f workspace: set title to header for aria
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-04 18:28:11 +02:00
Thomas Lamprecht
4cf3bf9510 utils: enable ARIA again
We had done so already in PBS and PMG since a bit without seeing
anything broken due to it, which makes sense as this was enabled for
*during* the step-by-step upgrade from ExtJS 4 to 5 (and then
directly 6).

Re-enabling  could help with some accessibility issues we have some
tangential reports[0].

[0]: https://github.com/nvaccess/nvda/issues/11530

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-04 18:23:47 +02:00
Thomas Lamprecht
ae8f688d77 ui: rework global searchfield, drop cruft, improve readability
Single letter variable names really do not help understanding what's
going on, as do overly general names like fields for the split up
words we actually search+filter for.
Using a switch block as map is often also not ideal (way more syntax
noise and style hacks like break on the same line to keep it
compact), rather just use an actual object map.

Some of the improvements where not possible when this was
implemented, as then we ensured < es5 compat for IE 10 support.

With for-of and nullish-chaining a few things to get nicer to
express.

While at it also fix comment text width making them less look like
haikus and improve match calculation comment to avoid implying that
match is either 0, 1 or 2, it can be higher too (if multiple columns
match).

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-04 18:10:02 +02:00
Thomas Lamprecht
e8fed6b628 d/postinst: actively remove pvetest repository (add for beta) again
in theory we'd need to be more cautios but this was added only during
beta, which is when we do not really provided any stability
guarantee, further, it's rather unlikely that one added very
important repos that, when removed, break something (again *during*
beta).

The new APT repo management makes it also easy to see when one does
not gets any PVE updates, and one can add the pvetest repo there
again easily too.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 23:50:57 +02:00
Thomas Lamprecht
5a96375098 ui: download do not clear meta info on certValidity change
Makes no sense, as the URL is the same so the info, if any at all, is
still valid - not counting the rather rare case where in the exact
moment one disables cert checking a MITM interception goes live ;-)

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 23:38:23 +02:00
Thomas Lamprecht
9ebd97fe06 ui: download: use view model for state handling
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 23:38:23 +02:00
Thomas Lamprecht
c42e3aa76e ui: auth schema: we use OpenID Connect
As OpenID is the old one, with several security implications/issues
present, so avoid suggesting that its used.

`OpenID Connect` revers to the "third gen" on top of oauth2

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 16:32:24 +02:00
Thomas Lamprecht
0bc0260983 ui: dc/auth: refactor openID edit window to be more static
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 16:31:43 +02:00
Thomas Lamprecht
8874fcb501 css: fix typo in property name
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 16:30:15 +02:00
Thomas Lamprecht
e646c719a2 bump version to 7.0-7
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 02:42:04 +02:00
Thomas Lamprecht
56bc50b8a8 ui: adapt task-history icon, use same as in PBS
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 02:41:02 +02:00
Thomas Lamprecht
8de6ef280c ui: minimally increase font-size of product title
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 02:05:06 +02:00
Thomas Lamprecht
ab9d07db99 Revert "add beta text with link to bugtracker"
This reverts commit 4d1bb8e50f.
2021-07-03 02:04:33 +02:00
Thomas Lamprecht
7810be88a4 Revert "ui: temporary disable repo config entry"
This reverts commit 48dd979c4b.
2021-07-03 01:33:42 +02:00
Thomas Lamprecht
d2ae3a96be bump version to 7.0-6
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 01:31:52 +02:00
Thomas Lamprecht
48dd979c4b ui: temporary disable repo config entry
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 01:26:44 +02:00
Thomas Lamprecht
a2692d6bf6 ui: storage: file download: rework code/UX a bit
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 01:20:15 +02:00
Thomas Lamprecht
01366f9e8c ui: move download URL to storage window into own file
As 200 lines is a bit much for the content view, i.e., basically
growing it by 50% in size for a very specific feature is not ideal.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 00:45:09 +02:00
Lorenz Stechauner
af3c0a9287 fix #1710: ui: storage: add download from url button
uses the common function PVE::Tools::download_file_from_url to
download a iso image or container template.

note: Only users with permissions `Sys.Audit` and `Sys.Modify` on
`/` are permitted to use the api endpoints due to security reasons.
(it is possible to download files from internal networks which would
be not visible/accessible from outside)

Signed-off-by: Lorenz Stechauner <l.stechauner@proxmox.com>
Reviewed-By: Dominik Csapak <d.csapak@proxmox.com>
2021-07-03 00:36:26 +02:00
Lorenz Stechauner
79035e5a0f ui: Utils: change download task format
Signed-off-by: Lorenz Stechauner <l.stechauner@proxmox.com>
Reviewed-By: Dominik Csapak <d.csapak@proxmox.com>
2021-07-03 00:36:24 +02:00
Lorenz Stechauner
17711ff849 api: nodes: add query_url_metadata method
metadata is gained using a HEAD request.

Due to the ability of this api endpoint to request files on internal
networks (which would not be visible/accessible from outside) it is
restricted to users with permissions `Sys.Audit` and `Sys.Modify` on
`/`. Users with these permissions are able to alter node (network)
config anyway, so this should not create any further security risk.

Signed-off-by: Lorenz Stechauner <l.stechauner@proxmox.com>
Reviewed-By: Dominik Csapak <d.csapak@proxmox.com>
2021-07-03 00:36:20 +02:00
Thomas Lamprecht
16f9dcb8a0 d/control: bump versioned dependency on proxmox-widget-toolkit to 3.2-1
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-03 00:35:50 +02:00
Thomas Lamprecht
879e27c496 ui: realms: use address-book as default fallback icon
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-02 21:59:42 +02:00
Thomas Lamprecht
da25c5ac41 ui: realms: add iconCls to menu entries
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-02 21:57:26 +02:00
Thomas Lamprecht
959df7bf26 ui: notes: use monospace font and make white-space pre-wrap in text area
can improve editing experience quite a bit when formating tables ore
the like.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-02 18:48:12 +02:00
Thomas Lamprecht
c2cd0c9eb3 ui: auth domains: openID: make 'username-claim' display-edit field
while we cannot allow editing it after realm creation it is still
interesting to know to which value it was set.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-02 15:26:58 +02:00
Dominik Csapak
c5be8d39c9 ui: Workspace: use domains info to hide password/tfa items
in the user menu

we have to make an additional api call here, since it is the only
place (currently) where we can get the realm type

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
 [ Thomas: adapt to move of parse_userid to widget-toolkit ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-02 15:20:16 +02:00
Thomas Lamprecht
b8dcc6d307 ui: user view: use username/realm renderer from widget-toolkit
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-02 15:18:44 +02:00