Function syntax, raw words, string templates, no prototype builtins
Signed-off-by: Dominic Jäger <d.jaeger@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
As 60% is pretty low, and normally still OK and even wanted to have
(no need for having an over-dimensioned setup with lots of unused
resources).
Note, this is not a off-by-one, I want to compare real bigger > 75%
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
this one would deserve much more, especially the newer backup job
detail and not-backed-up view should be split out and done in a
declarative way (view view-controller)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
My browser here is pretty fixated on the history, and due to some
unknown reason I got a history fragment string like:
`#v1:=0:=18:=4:::::::` so the "hashes" got into strings, and I was
not able to move them back.
Adding a match here to always try reverse-mapping the hash to the
original input helps to fix that here.
We'd only run into issues if we'd use a integer-string as id, but we
really don't (IIRC not even allowed in extjs) so this is safe to do.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
eslint complains about the window.confirm call, and neither I nor
some other colleagues here did see that dialogue ever in practice.
The confirm here does not adds any real value, as all other back
navigation are unprotected, but have similar potential in loosing
state.
One can always navigate forward via their user agent and for console
(noVNC, xterm.js) we have now a separate check.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
if passing the hook script command as string, it might get interpreted
as shell command with side-effects. this is pretty harmless, since only
root is allowed to set the script parameter anyway, but making it more
robust and future-proof does not hurt.
tested with a reproducer of "/bin/echo $(touch $(whoami))" as script
parameter, with a file with that name existing, being executable and
having the following contents:
----8<----
echo "hello from hook script"
---->8----
without this change, the hookscript itself is not executed, but
'/bin/sh -c "/bin/echo $(touch $(whoami)) job"' and similar calls are,
which cause the file 'root' to be touched in the current working
directory of the vzdump process (or task worker).
with this change, the file is executed as is without any side-effects of
shell commands in the file name, and the 'hello from hook script' lines
are printed whenever the hook script is called by vzdump.
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Also rename disks to blockdevices, as especially with the iSCSI stuff
the listed devices do not necessarily need to be real disks.
Grouping current(ish) load info in it's own system-load section seems
to be a better fit in general too.
bios/pci stuff is all hardware, so group it there to avoid adding to
much sections.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Makes all report-def entries hashes which allows to drop some
handling for the ARRAY ref case.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
And move the helper methods up and scope them to module-local only
Uses the fact that perl methods return the last statement, so the
dir2text sub closures in the command list do not need to be changed
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>