]> git.proxmox.com Git - pve-manager.git/log
pve-manager.git
3 years agoreport: add multipath.conf and wwids file
Mira Limbeck [Fri, 16 Apr 2021 13:15:54 +0000 (15:15 +0200)]
report: add multipath.conf and wwids file

These 2 files can be helpful for issues with multipath. The multipath -v3
output is too large most of the time and not required for analyzing and
solving the issues.

Signed-off-by: Mira Limbeck <m.limbeck@proxmox.com>
3 years agobump version to 6.3-7
Thomas Lamprecht [Thu, 15 Apr 2021 17:57:14 +0000 (19:57 +0200)]
bump version to 6.3-7

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoapi: resources: only get guest lock after real access check
Thomas Lamprecht [Thu, 15 Apr 2021 17:44:59 +0000 (19:44 +0200)]
api: resources: only get guest lock after real access check

The guest iteration is slightly confusing as we also handle the
accumulated pool settings there, so we only check the VM.Audit privs.
for a specific VM and skip to the next if the permissions is not
there after those pool handling.

So, move operations which are only required when VM privs. are there
below this check.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoapi: resources: push guest, pool and sdn info sorted
Thomas Lamprecht [Thu, 15 Apr 2021 17:33:26 +0000 (19:33 +0200)]
api: resources: push guest, pool and sdn info sorted

makes it easier to compare in API responses, and those list are not
huge, seldom over a few thousands, which is peanut crumbs compared to
all the other thing in this perl stack.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: use byte unit and power-of-two base for memory rrd graphs
Thomas Lamprecht [Thu, 15 Apr 2021 17:31:00 +0000 (19:31 +0200)]
ui: use byte unit and power-of-two base for memory rrd graphs

To better match the gauge in the current status infobox in the same
summary panel, which is already using a format where KiB is 1024

the latter needs a (not yet bumped) widget toolkit update to 2.5-2 or
newer, just setting now to avoid forgetting it.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: live restore: make warning to a shorter note
Thomas Lamprecht [Thu, 15 Apr 2021 15:21:47 +0000 (17:21 +0200)]
ui: live restore: make warning to a shorter note

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: restore: add live-restore checkbox
Stefan Reiter [Wed, 3 Mar 2021 09:56:12 +0000 (10:56 +0100)]
ui: restore: add live-restore checkbox

Add 'isPBS' parameter for Restore window so we can detect when to show
the 'live-restore' checkbox.

Includes a warning about this feature being experimental for now.

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
3 years agovzdump: getlock: return lock file handle and let the caller close it
Fabian Ebner [Mon, 12 Apr 2021 08:47:31 +0000 (10:47 +0200)]
vzdump: getlock: return lock file handle and let the caller close it

so it doesn't get out of scope too early.

Regression introduced by 5620e5761efc6617ee8e8b004cfdd604547125fc as pointed
out by Fabian Grünbichler.

Reported in the community forum:
https://forum.proxmox.com/threads/limit-simultaneous-backup-jobs.87489

Suggested-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agovzdump: storage info: move out activate storage call
Fabian Ebner [Thu, 11 Mar 2021 09:22:05 +0000 (10:22 +0100)]
vzdump: storage info: move out activate storage call

Otherwise storage_info() cannot be used for (at least) PBS storages from an API
call without 'protected => 1', because the password cannot be read from
'/etc/pve/priv'. Note that the function itself does not need the storage to be
active, because it only uses storage_config() and get_backup_dir().

AFAICT new() is the only existing user of this function and can be responsible
for activating the storage itself.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agojs: readd SLAAC option to IPConfig
Mira Limbeck [Mon, 29 Mar 2021 12:07:16 +0000 (14:07 +0200)]
js: readd SLAAC option to IPConfig

Now that SLAAC is supported, we can revert commit 793f2cf4.
SLAAC requires cloud-init 19.4 or newer.

Signed-off-by: Mira Limbeck <m.limbeck@proxmox.com>
3 years agoui: backups: enable editing notes for Proxmox Backup Server
Dominik Csapak [Tue, 24 Nov 2020 09:09:36 +0000 (10:09 +0100)]
ui: backups: enable editing notes for Proxmox Backup Server

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: cluster task log: eslint fixes
Fabian Ebner [Fri, 12 Mar 2021 12:53:26 +0000 (13:53 +0100)]
ui: cluster task log: eslint fixes

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agometrix: influx: fix default api_prefix
Dominik Csapak [Mon, 15 Mar 2021 14:28:11 +0000 (15:28 +0100)]
metrix: influx: fix default api_prefix

we set the api prefix by default to '/' so we always triggered
the the replacement and added '///' which is wrong and does not
work for the 'health' api path
(influxdb returns 404 for 'https://ip:port///health')

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agometrics: influx: special case 'health' api path i _get_v2url
Dominik Csapak [Mon, 15 Mar 2021 14:26:46 +0000 (15:26 +0100)]
metrics: influx: special case 'health' api path i _get_v2url

the forwards compatible api of 1.8 only contains this path
(not api/v2/health) and it it also contained in the v2 api

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agoui: metrics: influxdb: add support for new api-path-prefix field
Thomas Lamprecht [Mon, 15 Mar 2021 08:14:57 +0000 (09:14 +0100)]
ui: metrics: influxdb: add support for new api-path-prefix field

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agometrics: influx: allow one to add an API URL-path prefix
Thomas Lamprecht [Mon, 15 Mar 2021 08:14:56 +0000 (09:14 +0100)]
metrics: influx: allow one to add an API URL-path prefix

I normally use a reverse proxy in front of my influxdb instances,
proxying all from the /influx/ path to the only locally listening
influxdb. So here I'd need to set "influx" as api-path-prefix.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agometrics: influx: do not error out when credendtials could not be loaded
Thomas Lamprecht [Mon, 15 Mar 2021 08:14:55 +0000 (09:14 +0100)]
metrics: influx: do not error out when credendtials could not be loaded

Not a hard error, some network box (proxy) down the line could add it
for us, or it could be just not required, so ...

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agometrics: influx: send along auth token on connection test too
Thomas Lamprecht [Mon, 15 Mar 2021 08:14:54 +0000 (09:14 +0100)]
metrics: influx: send along auth token on connection test too

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agometrics: influx: include unrecognized protocol value in error
Thomas Lamprecht [Mon, 15 Mar 2021 08:14:53 +0000 (09:14 +0100)]
metrics: influx: include unrecognized protocol value in error

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: avoid errors when 'template' property is not present in guest status
Fabian Ebner [Thu, 11 Mar 2021 10:26:46 +0000 (11:26 +0100)]
ui: avoid errors when 'template' property is not present in guest status

The API doesn't advertise the property as non-optional and it's safer and more
in line with the surrounding code.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agoui: restore: fix bandwidth limit behavior
Fabian Ebner [Mon, 15 Mar 2021 11:57:29 +0000 (12:57 +0100)]
ui: restore: fix bandwidth limit behavior

by allowing zero and updating the field name. Otherwise the hint mentioning zero
is wrong. Also, it's not only a read limit as the emptyText already indicates.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agoui: bandwidth limit selector: make it possible to allow zero
Fabian Ebner [Mon, 15 Mar 2021 11:57:28 +0000 (12:57 +0100)]
ui: bandwidth limit selector: make it possible to allow zero

The initial value is '' and in getSubmitValue(), previously the branch
   if (v == 0 || v == 0.0) return null;
was taken, because of the lax '==' comparision. Make sure we still return null
for '' by explicitly checking for it.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agoext. metris. fixup InfluxDB spelling in schema and code style
Thomas Lamprecht [Sat, 13 Mar 2021 20:30:03 +0000 (21:30 +0100)]
ext. metris. fixup InfluxDB spelling in schema and code style

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agobump version to 6.3-6
Thomas Lamprecht [Tue, 9 Mar 2021 07:34:03 +0000 (08:34 +0100)]
bump version to 6.3-6

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui/hardware: extend machine renderer to show pinned Windows versions
Stefan Reiter [Mon, 8 Mar 2021 10:01:51 +0000 (11:01 +0100)]
ui/hardware: extend machine renderer to show pinned Windows versions

The default is not just "i440fx", this hides the fact that the version
will be pinned to 5.1, unless one deliberately opens the editor.

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
3 years agoUtils: add is_windows and use in MachineEdit
Stefan Reiter [Mon, 8 Mar 2021 10:01:50 +0000 (11:01 +0100)]
Utils: add is_windows and use in MachineEdit

A bit more future proof and reuseable than a regex match.

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
3 years agoui/machine: fix eslint warning (unnecessary parentheses)
Stefan Reiter [Mon, 8 Mar 2021 10:01:49 +0000 (11:01 +0100)]
ui/machine: fix eslint warning (unnecessary parentheses)

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
3 years agoui/machine: fix Windows pinning and detect "pc" as non-pinned
Stefan Reiter [Mon, 8 Mar 2021 10:01:48 +0000 (11:01 +0100)]
ui/machine: fix Windows pinning and detect "pc" as non-pinned

We need to detect "isWindows" before splitting a pinned version into
.version/.machine, otherwise .machine will always be "pc" or "q35", and
the check in "isWindows" will succeed even for pinned versions. This
resulted in "5.1" being shown even if a different version has been set
for a Windows machine.

Also alias "pc" directly to "__default__", as they have the same
meaning, but "pc" is not a valid entry in the "machine" combobox,
leading to an invalid state when editing the (valid) configuration of
"machine: pc" on a VM.

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
3 years agoui: add onlineHelp to rng
Stefan Reiter [Mon, 8 Mar 2021 10:01:47 +0000 (11:01 +0100)]
ui: add onlineHelp to rng

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
3 years agobump version to 6.3-5
Thomas Lamprecht [Fri, 5 Mar 2021 20:50:08 +0000 (21:50 +0100)]
bump version to 6.3-5

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: vm/machine: show autopinned version for win VM
Thomas Lamprecht [Fri, 5 Mar 2021 21:21:41 +0000 (22:21 +0100)]
ui: vm/machine: show autopinned version for win VM

and improve switchting machine type and keeping same version for
the windows based VMs, as we cannot do the same as for other
OS-Types, just select the "latest" magic version.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agopartially fix #2745: vzdump: use default for remove parameter
Fabian Ebner [Wed, 3 Mar 2021 11:50:41 +0000 (12:50 +0100)]
partially fix #2745: vzdump: use default for remove parameter

The initial default from the $confdesc is 1 anyways, and like
this changing the default in /etc/vzdump.conf to 0 actually works.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: vm/machine: show notice about effects of machine version change
Thomas Lamprecht [Fri, 5 Mar 2021 20:13:48 +0000 (21:13 +0100)]
ui: vm/machine: show notice about effects of machine version change

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: vm/machine: allow blank to avoid invalidity and show Latest as empty text
Thomas Lamprecht [Fri, 5 Mar 2021 19:44:05 +0000 (20:44 +0100)]
ui: vm/machine: allow blank to avoid invalidity and show Latest as empty text

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: vm/machine: only set advanced temporary visible for pinned machines
Thomas Lamprecht [Fri, 5 Mar 2021 19:41:44 +0000 (20:41 +0100)]
ui: vm/machine: only set advanced temporary visible for pinned machines

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: vm/machine: avoid showing latest for windows VMs
Thomas Lamprecht [Fri, 5 Mar 2021 19:03:34 +0000 (20:03 +0100)]
ui: vm/machine: avoid showing latest for windows VMs

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: style followup cleanup
Thomas Lamprecht [Fri, 5 Mar 2021 19:01:46 +0000 (20:01 +0100)]
ui: style followup cleanup

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: vm/machine: adapt to API changes
Thomas Lamprecht [Fri, 5 Mar 2021 16:40:52 +0000 (17:40 +0100)]
ui: vm/machine: adapt to API changes

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: MachineEdit: add option for machine version pinning
Stefan Reiter [Thu, 4 Mar 2021 12:52:09 +0000 (13:52 +0100)]
ui: MachineEdit: add option for machine version pinning

Hidden behind "Advanced" options, as to not confuse inexperienced users.

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: create MachineEdit window
Stefan Reiter [Thu, 4 Mar 2021 12:52:08 +0000 (13:52 +0100)]
ui: create MachineEdit window

no functional change intended

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoapi: node: add capabilities path and move qemu machines over
Thomas Lamprecht [Fri, 5 Mar 2021 16:07:17 +0000 (17:07 +0100)]
api: node: add capabilities path and move qemu machines over

avoid further crowding the top-level node API path with such
"what can some part of the node currently do" stuff, rather move it
down.

The QEMU cpu stuff should move also down there.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoapi: nodes: sort use statements
Thomas Lamprecht [Fri, 5 Mar 2021 15:57:42 +0000 (16:57 +0100)]
api: nodes: sort use statements

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoapi: register Qemu::Machine call
Stefan Reiter [Thu, 4 Mar 2021 12:52:07 +0000 (13:52 +0100)]
api: register Qemu::Machine call

as 'machine-types', so it is clear this refers to QEMU machines, not the
local machine (as one might think, this being a 'node' API call).

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agobuildsys: api: sort sources
Thomas Lamprecht [Fri, 5 Mar 2021 15:52:37 +0000 (16:52 +0100)]
buildsys: api: sort sources

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoapi: nodes: sort index
Thomas Lamprecht [Fri, 5 Mar 2021 15:50:28 +0000 (16:50 +0100)]
api: nodes: sort index

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agometric status: fix misspelled method call
Thomas Lamprecht [Sat, 27 Feb 2021 15:11:08 +0000 (16:11 +0100)]
metric status: fix misspelled method call

reported in:
https://forum.proxmox.com/threads/typo-in-influxdb-pm.85017/

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: zpool status detail: reuse existing translation
Thomas Lamprecht [Fri, 26 Feb 2021 08:15:26 +0000 (09:15 +0100)]
ui: zpool status detail: reuse existing translation

this is not something one really questions when not there, so avoid
adding a extra overly specific translation as "No Data" fits quite
well..

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: zpool status detail: add default for scrub information
Stoiko Ivanov [Thu, 25 Feb 2021 21:23:05 +0000 (22:23 +0100)]
ui: zpool status detail: add default for scrub information

in case a zpool has not been yet scrubbed, there is no 'scan'
information in `zpool status` output.

Adding a informational text in that case might help users to notice
that something is not configured optimally (e.g. disabled cronjob)

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
3 years agovzdump: indentation and whitespace fixes
Thomas Lamprecht [Thu, 25 Feb 2021 18:21:18 +0000 (19:21 +0100)]
vzdump: indentation and whitespace fixes

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agovzdump: avoid single argument bless
Thomas Lamprecht [Thu, 25 Feb 2021 18:19:03 +0000 (19:19 +0100)]
vzdump: avoid single argument bless

reported by perlcritic.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agovzdump: avoid bareword file handles and two argument open
Thomas Lamprecht [Thu, 25 Feb 2021 18:17:40 +0000 (19:17 +0100)]
vzdump: avoid bareword file handles and two argument open

reported by perlcritic. The bareword file handles will be depreacated
in the future in perl, so start replacing now..

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agovzdump: PBS: make task log upload error non-fatal
Thomas Lamprecht [Thu, 25 Feb 2021 12:59:42 +0000 (13:59 +0100)]
vzdump: PBS: make task log upload error non-fatal

We want to continue in that case, this is not really essential so
only warn about it.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: firewall grid: try balance between flex and good overview
Thomas Lamprecht [Mon, 22 Feb 2021 13:30:53 +0000 (14:30 +0100)]
ui: firewall grid: try balance between flex and good overview

Recently, with the Proxmox Backup sync/verify/.. job grids I had to
change my mind regarding use of flex, overuse of it is as bad as
having all to fixed widths as it spreads out the data a lot on big
screens, making it hard to follow as lots of eye movement is
required.

What we ideally would have is a "maxFlexWidth", i.e., a maximal
auto-flex width which still allows wider columns if a user manually
drags it wider. "maxWidth" comes close, but is a hard limit and so
use it only in cases where its quite clear that wider columns make no
sense (surely someone will disagree even for those, but well...).

Basic solution is to add lots more flex ratio to comment so that the
others won't get to big fast, keeping the actual relevant config of a
rule somewhat close by (thus easier to read/grasp/parse)

Also move the source/destination port columns after their direction
column and abbreviate their header title.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: firewall grid: rename Enable column to shorter On
Thomas Lamprecht [Mon, 22 Feb 2021 13:30:08 +0000 (14:30 +0100)]
ui: firewall grid: rename Enable column to shorter On

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: firewall grid: fix rendering comment, only show tooltip when truncated
Thomas Lamprecht [Mon, 22 Feb 2021 13:28:35 +0000 (14:28 +0100)]
ui: firewall grid: fix rendering comment, only show tooltip when truncated

avoid showing "undefined" if there's no comment, renderer must not
return null or undefined directly, it will converted to string as is,
so always fallback to '' empty string

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: FirewallRules: Add tooltip to comments
Aaron Lauterer [Mon, 22 Feb 2021 10:16:26 +0000 (11:16 +0100)]
ui: FirewallRules: Add tooltip to comments

The comment columns might not be wide enough for longer comments. Since
it is the most right columns, it can be tricky to grab the right pixel
to drag it wider.

A tooltip that shows up on hover should be okay.

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
3 years agoui: FirewallRules: make columns flexible
Aaron Lauterer [Mon, 22 Feb 2021 10:16:25 +0000 (11:16 +0100)]
ui: FirewallRules: make columns flexible

Changing the width definitions to use flex will make better use on
larger monitors. Changing the `width` parameter to `minWidth` ensures
that on smaller screens it is still usable, though some horizontal
scrolling might be necessary.

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
3 years agod/control: bump versioned depdnency on guest commnon library
Thomas Lamprecht [Fri, 19 Feb 2021 17:16:19 +0000 (18:16 +0100)]
d/control: bump versioned depdnency on guest commnon library

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agobump version to 6.3-4
Thomas Lamprecht [Fri, 19 Feb 2021 16:53:36 +0000 (17:53 +0100)]
bump version to 6.3-4

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: qemu/HardwareView: fix CDRom permission checkss
Aaron Lauterer [Fri, 12 Feb 2021 15:57:51 +0000 (16:57 +0100)]
ui: qemu/HardwareView: fix CDRom permission checkss

There are several types of drives that use the same config keys. Most
notably CDRom and regular VM disks (EFI and cloudinit exist as well).

Since there is a dedicated permission for CDRom drives we need to check
permissions in more detail, depending on what type of drive it actually
is for things like the edit, remove and Add -> CDRom buttons.

The permission check in the row definition itself which only checked for
'VM.Config.Disk' permissions (never_delete) had to be removed and finer
grained checks added for the individual buttons. This also meant a bit
of reshuffling in the checks what kind of disk the current one is.

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: vm/hardware: cleanup and constify variables
Thomas Lamprecht [Fri, 19 Feb 2021 16:22:24 +0000 (17:22 +0100)]
ui: vm/hardware: cleanup and constify variables

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: qemu/HardwareView: eslint: enforce "no-shadow" rule
Aaron Lauterer [Fri, 12 Feb 2021 15:57:49 +0000 (16:57 +0100)]
ui: qemu/HardwareView: eslint: enforce "no-shadow" rule

By removing global vars 'i' and 'confid' and declaring them with let in the needed
context.

'i' wasn't necessary but had to be touched anyway.

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
3 years agoui: qemu/HardwareView: eslint: enforce "no-useless-concat" rule
Aaron Lauterer [Fri, 12 Feb 2021 15:57:48 +0000 (16:57 +0100)]
ui: qemu/HardwareView: eslint: enforce "no-useless-concat" rule

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
3 years agoui: vm/hardware: adapt maxlen fix
Thomas Lamprecht [Fri, 19 Feb 2021 15:45:06 +0000 (16:45 +0100)]
ui: vm/hardware: adapt maxlen fix

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: qemu/HardwareView: eslint: enforce "max-len" rule
Aaron Lauterer [Fri, 12 Feb 2021 15:57:47 +0000 (16:57 +0100)]
ui: qemu/HardwareView: eslint: enforce "max-len" rule

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
3 years agoui: dc/TokenEdit: fix editing existing tokens
Dominik Csapak [Fri, 12 Feb 2021 15:01:15 +0000 (16:01 +0100)]
ui: dc/TokenEdit: fix editing existing tokens

we always have to calculate the url correctly, not only on creation
otherwise we try to edit the token by doing a 'PUT' request on
/access/users
and not on
/access/users/USERID/token/TOKENID

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agoui: window/Settings: fix labelWidth for saved user name
Dominik Csapak [Fri, 19 Feb 2021 14:27:00 +0000 (15:27 +0100)]
ui: window/Settings: fix labelWidth for saved user name

Somewhere during rendering of the window, extjs wants to add 5px to
the labelwidth for the surrounding container. Having a string here
results in the container having a width of 1505px instead of 155px and
the value of the field is far off to the right and not visible.

Changing to a number fixes that.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agotest: vzdump: rename vzdump_new_retention_test.pl to vzdump_new_test.pl
Fabian Ebner [Mon, 15 Feb 2021 12:25:02 +0000 (13:25 +0100)]
test: vzdump: rename vzdump_new_retention_test.pl to vzdump_new_test.pl

as it now also includes tests for new() with non-retention options.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
Reviewed-By: Dominik Csapak <d.csapak@proxmox.com>
3 years agotest: vzdump: add tests for mailto
Fabian Ebner [Mon, 15 Feb 2021 12:25:01 +0000 (13:25 +0100)]
test: vzdump: add tests for mailto

Re-use the existing code, by allowing special kinds of 'tests' that just set
the options that are tested for.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
Reviewed-By: Dominik Csapak <d.csapak@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agovzdump: refactor parsing mailto so it can be mocked
Fabian Ebner [Mon, 15 Feb 2021 12:25:00 +0000 (13:25 +0100)]
vzdump: refactor parsing mailto so it can be mocked

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
Reviewed-By: Dominik Csapak <d.csapak@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: snapshot: show task viewer for progress log
Stefan Reiter [Mon, 8 Feb 2021 11:15:12 +0000 (12:15 +0100)]
ui: snapshot: show task viewer for progress log

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
3 years agod/control: bump versioned dependency for libpve-storage-perl
Thomas Lamprecht [Tue, 9 Feb 2021 12:39:16 +0000 (13:39 +0100)]
d/control: bump versioned dependency for libpve-storage-perl

to ensure the diskmanage list disk API supports the
"include-partitions" parameter

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: disk list: include partitions
Fabian Ebner [Mon, 8 Feb 2021 14:23:29 +0000 (15:23 +0100)]
ui: disk list: include partitions

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agofixes #3066: resourcestore: add vm hostcpu/hostmem fields
Alexandre Derumier [Fri, 23 Oct 2020 14:50:50 +0000 (16:50 +0200)]
fixes #3066: resourcestore: add vm hostcpu/hostmem fields

This add new fields with cpu/mem percent usage of vms,
relative to host maxcpu/maxmem.

Currently, we can't sort easily most consumming vm on a host.

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
3 years agoceph: add get api call for single pool
Alwin Antreich [Tue, 12 Jan 2021 10:21:47 +0000 (11:21 +0100)]
ceph: add get api call for single pool

Information of a single pool can be queried.

Signed-off-by: Alwin Antreich <a.antreich@proxmox.com>
3 years agoceph: add titles to ceph_pool_common_options
Alwin Antreich [Tue, 12 Jan 2021 10:21:46 +0000 (11:21 +0100)]
ceph: add titles to ceph_pool_common_options

Signed-off-by: Alwin Antreich <a.antreich@proxmox.com>
3 years agoceph: setpool, use parameter extraction instead
Alwin Antreich [Tue, 12 Jan 2021 10:21:45 +0000 (11:21 +0100)]
ceph: setpool, use parameter extraction instead

of the unneeded ref copy for params.

Signed-off-by: Alwin Antreich <a.antreich@proxmox.com>
3 years agoapi: ceph: subclass pools
Alwin Antreich [Tue, 12 Jan 2021 10:21:44 +0000 (11:21 +0100)]
api: ceph: subclass pools

for better handling and since the pool endpoints got more entries.

Signed-off-by: Alwin Antreich <a.antreich@proxmox.com>
3 years agoapi: Ceph: add reminder to remove 'disks' call
Fabian Ebner [Tue, 26 Jan 2021 11:45:28 +0000 (12:45 +0100)]
api: Ceph: add reminder to remove 'disks' call

This API call is the predecessor of /nodes/{node}/disks/list, which has seen a
few more improvements. The latter API call should be used instead, and the web
UI already does so.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agoui: qemu/HardwareView: check EFI Disk button permissions
Aaron Lauterer [Mon, 1 Feb 2021 14:21:30 +0000 (15:21 +0100)]
ui: qemu/HardwareView: check EFI Disk button permissions

Make sure that the `Add EFI Disk` button is disabled if the user does
not have the needed permissions.

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
3 years agoui: qemu/HardwareView: change heuristic perms to const
Aaron Lauterer [Mon, 1 Feb 2021 14:21:29 +0000 (15:21 +0100)]
ui: qemu/HardwareView: change heuristic perms to const

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
3 years agoui: qemu/HardwareView: eslint: enforce "no-mixed-operators" rule
Aaron Lauterer [Mon, 1 Feb 2021 14:21:25 +0000 (15:21 +0100)]
ui: qemu/HardwareView: eslint: enforce "no-mixed-operators" rule

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
3 years agoui: dc/MetricServerView: add onlineHelp to edit windows
Dominik Csapak [Wed, 2 Dec 2020 09:21:12 +0000 (10:21 +0100)]
ui: dc/MetricServerView: add onlineHelp to edit windows

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agoui: add necessary fields for influxdb http api
Dominik Csapak [Wed, 2 Dec 2020 09:21:11 +0000 (10:21 +0100)]
ui: add necessary fields for influxdb http api

and en/disable them accordingly to the selected mode

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agostatus/influxdb: remove unnecessary comment
Dominik Csapak [Wed, 2 Dec 2020 09:21:10 +0000 (10:21 +0100)]
status/influxdb: remove unnecessary comment

we already have that information in the reference docs, no need to
have it here as well

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agostatus/influxdb: implement influxdb 2.x http api
Dominik Csapak [Wed, 2 Dec 2020 09:21:09 +0000 (10:21 +0100)]
status/influxdb: implement influxdb 2.x http api

needs an organization/bucket (previously db) and an optional token
the http client does not fit exactly in the connect/send/disconnect
scheme, so it simply creates a request in 'connect',
does the actual http connection in 'send' and nothing in 'disconnect'

max-body-size is set to 25.000.000 bytes by default (the influxdb default)
and the timeout to 1 second (same as default graphite tcp timeout)

the token (if given) gets saved in /etc/pve/priv/metricserver/$ID.pw
it is optional, because the 1.8.x compatibility api does not need
authentication (in contrast to influxdb 2.x)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agostatus/plugin: extend with add/update/delete hooks
Dominik Csapak [Wed, 2 Dec 2020 09:21:08 +0000 (10:21 +0100)]
status/plugin: extend with add/update/delete hooks

like we do in it for the storage section configs

we will need this to store the token for influxdbs http api

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agostatus/plugin: extend send/_connect/_disconnect/test_connection
Dominik Csapak [Wed, 2 Dec 2020 09:21:07 +0000 (10:21 +0100)]
status/plugin: extend send/_connect/_disconnect/test_connection

by providing the id or cfg to have better context in those methods
we will need that for influxdb http api

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agoapi: cluster/metricserver: prevent simultaneosly setting and deleting of property
Dominik Csapak [Wed, 2 Dec 2020 09:21:06 +0000 (10:21 +0100)]
api: cluster/metricserver: prevent simultaneosly setting and deleting of property

like we do in other apis of section configs (e.g. storage)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
3 years agopvereport: also add .sources files
Fabian Ebner [Wed, 27 Jan 2021 10:43:20 +0000 (11:43 +0100)]
pvereport: also add .sources files

while this format is probably not much in use currently, the plan is to make it
the default format in Debian, see 'man 5 sources.list'.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agovzdump: avoid parsing already parsed option
Fabian Ebner [Fri, 15 Jan 2021 12:49:05 +0000 (13:49 +0100)]
vzdump: avoid parsing already parsed option

When a job is updated, verify_vzdump_parameters() is called twice. This led to
parse_property_string being called with the already parsed option.

Reported on the pve-user mailing list:
https://lists.proxmox.com/pipermail/pve-user/2021-January/172258.html

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agopvereport: add apt sources
Stoiko Ivanov [Tue, 26 Jan 2021 17:31:38 +0000 (18:31 +0100)]
pvereport: add apt sources

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
3 years agoui: ceph: fix keeping selection after operation
Fabian Ebner [Tue, 26 Jan 2021 13:01:12 +0000 (14:01 +0100)]
ui: ceph: fix keeping selection after operation

Found by having the console open and getting a message that 'me' (the
controller) does not have a method getRootNode()

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
3 years agoui: eslint: some more trailing comma fixes
Thomas Lamprecht [Tue, 19 Jan 2021 16:48:50 +0000 (17:48 +0100)]
ui: eslint: some more trailing comma fixes

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: eslint: enforce "dot-notation" rule
Thomas Lamprecht [Tue, 19 Jan 2021 16:45:01 +0000 (17:45 +0100)]
ui: eslint: enforce "dot-notation" rule

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: eslint: enforce "no-extra-boolean-cast" rule
Thomas Lamprecht [Tue, 19 Jan 2021 16:43:40 +0000 (17:43 +0100)]
ui: eslint: enforce "no-extra-boolean-cast" rule

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: eslint: enforce "no-extra-parens" rule
Thomas Lamprecht [Tue, 19 Jan 2021 16:42:36 +0000 (17:42 +0100)]
ui: eslint: enforce "no-extra-parens" rule

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: eslint: enforce "no-unneeded-ternary" rule
Thomas Lamprecht [Tue, 19 Jan 2021 16:41:11 +0000 (17:41 +0100)]
ui: eslint: enforce "no-unneeded-ternary" rule

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: eslint: fix various spacing related issues
Thomas Lamprecht [Tue, 19 Jan 2021 16:39:15 +0000 (17:39 +0100)]
ui: eslint: fix various spacing related issues

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
3 years agoui: eslint: fix trailing comma and comma related whitespaces errors
Thomas Lamprecht [Tue, 19 Jan 2021 16:31:03 +0000 (17:31 +0100)]
ui: eslint: fix trailing comma and comma related whitespaces errors

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>