Merge 7.4-17
This commit is contained in:
commit
25ae30ea65
89
Makefile
89
Makefile
@ -2,67 +2,80 @@
|
||||
#include /usr/share/dpkg/architecture.mk
|
||||
include defines.mk
|
||||
|
||||
export PVERELEASE=${DEB_VERSION_UPSTREAM}
|
||||
export VERSION=${DEB_VERSION_UPSTREAM_REVISION}
|
||||
export PVERELEASE = $(shell echo $(DEB_VERSION_UPSTREAM) | cut -c 1-3)
|
||||
export VERSION = $(DEB_VERSION_UPSTREAM_REVISION)
|
||||
|
||||
DESTDIR=
|
||||
|
||||
SUBDIRS = aplinfo PVE bin www services configs network-hooks test
|
||||
|
||||
GITVERSION:=$(shell git rev-parse HEAD)
|
||||
GITVERSION:=$(shell git rev-parse --short=8 HEAD)
|
||||
|
||||
# possibly set via debian/rules(.env)
|
||||
REPOID?=$(shell git rev-parse --short=8 HEAD)
|
||||
|
||||
DEB=${PACKAGE}_${VERSION}_${DEB_BUILD_ARCH}.deb
|
||||
BUILDDIR = $(PACKAGE)-$(DEB_VERSION_UPSTREAM)
|
||||
|
||||
all: ${SUBDIRS}
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i; done
|
||||
DSC=$(PACKAGE)_$(DEB_VERSION).dsc
|
||||
DEB=$(PACKAGE)_$(DEB_VERSION)_$(DEB_HOST_ARCH).deb
|
||||
|
||||
all: $(SUBDIRS)
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i; done
|
||||
|
||||
.PHONY: check
|
||||
check: bin test www
|
||||
${MAKE} -C bin check
|
||||
${MAKE} -C test check
|
||||
${MAKE} -C www check
|
||||
$(MAKE) -C bin check
|
||||
$(MAKE) -C test check
|
||||
$(MAKE) -C www check
|
||||
|
||||
.PHONY: dinstall
|
||||
dinstall: ${DEB}
|
||||
dpkg -i ${DEB}
|
||||
dinstall: $(DEB)
|
||||
dpkg -i $(DEB)
|
||||
|
||||
.PHONY: deb
|
||||
$(BUILDDIR):
|
||||
rm -rf $@ $@.tmp
|
||||
mkdir $@.tmp
|
||||
rsync -a * $@.tmp
|
||||
echo "git clone git://git.proxmox.com/git/pve-manager.git\\ngit checkout $(GITVERSION)" > $@.tmp/debian/SOURCE
|
||||
echo "REPOID_GENERATED=$(GITVERSION)" > $@.tmp/debian/rules.env
|
||||
mv $@.tmp $@
|
||||
|
||||
.PHONY: deb dsc
|
||||
deb: $(DEB)
|
||||
$(DEB):
|
||||
rm -rf dest
|
||||
mkdir dest
|
||||
rsync -a * dest
|
||||
echo "git clone git://git.proxmox.com/git/pve-manager.git\\ngit checkout ${GITVERSION}" > dest/debian/SOURCE
|
||||
echo "REPOID_GENERATED=${REPOID}" > dest/debian/rules.env
|
||||
cd dest; dpkg-buildpackage -b -us -uc
|
||||
lintian ${DEB}
|
||||
$(DEB): $(BUILDDIR)
|
||||
cd $(BUILDDIR); dpkg-buildpackage -b -us -uc
|
||||
lintian $(DEB)
|
||||
|
||||
dsc:
|
||||
rm -rf $(BUILDDIR) $(DSC)
|
||||
$(MAKE) $(DSC)
|
||||
lintian $(DSC)
|
||||
$(DSC): $(BUILDDIR)
|
||||
cd $(BUILDDIR); dpkg-buildpackage -S -us -uc -d
|
||||
|
||||
sbuild: $(DSC)
|
||||
sbuild $<
|
||||
|
||||
.PHONY: upload
|
||||
upload: ${DEB} check
|
||||
# check if working directory is clean
|
||||
git diff --exit-code --stat && git diff --exit-code --stat --staged
|
||||
tar cf - ${DEB} | ssh -X repoman@repo.proxmox.com upload --product pve --dist bullseye
|
||||
upload: UPLOAD_DIST ?= $(DEB_DISTRIBUTION)
|
||||
upload: $(DEB)
|
||||
tar cf - $(DEB) | ssh -X repoman@repo.proxmox.com upload --product pve --dist $(UPLOAD_DIST)
|
||||
|
||||
.PHONY: install
|
||||
install: vzdump-hook-script.pl
|
||||
install -d -m 0700 ${DESTDIR}/var/log/pveproxy
|
||||
install -d ${DOCDIR}/examples
|
||||
install -d ${DESTDIR}/var/lib/${PACKAGE}
|
||||
install -d ${DESTDIR}/var/lib/vz/images
|
||||
install -d ${DESTDIR}/var/lib/vz/template/cache
|
||||
install -d ${DESTDIR}/var/lib/vz/template/iso
|
||||
install -m 0644 vzdump-hook-script.pl ${DOCDIR}/examples/vzdump-hook-script.pl
|
||||
install -m 0644 spice-example-sh ${DOCDIR}/examples/spice-example-sh
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
install -d -m 0700 $(DESTDIR)/var/log/pveproxy
|
||||
install -d $(DOCDIR)/examples
|
||||
install -d $(DESTDIR)/var/lib/$(PACKAGE)
|
||||
install -d $(DESTDIR)/var/lib/vz/images
|
||||
install -d $(DESTDIR)/var/lib/vz/template/cache
|
||||
install -d $(DESTDIR)/var/lib/vz/template/iso
|
||||
install -m 0644 vzdump-hook-script.pl $(DOCDIR)/examples/vzdump-hook-script.pl
|
||||
install -m 0644 spice-example-sh $(DOCDIR)/examples/spice-example-sh
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
|
||||
.PHONY: distclean
|
||||
distclean: clean
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
find . -name '*~' -exec rm {} ';'
|
||||
rm -rf dest country.dat *.deb *.buildinfo *.changes ca-tmp
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
rm -f $(PACKAGE)*.tar* country.dat *.deb *.dsc *.build *.buildinfo *.changes
|
||||
rm -rf dest $(PACKAGE)-[0-9]*/
|
||||
|
@ -104,6 +104,8 @@ __PACKAGE__->register_method ({
|
||||
},
|
||||
repoid => {
|
||||
type => 'string',
|
||||
# length 8 is old (< 8.0) short-id, 16 is new short id, 40 is sha1 and 64 is sha256
|
||||
pattern => '[0-9a-fA-F]{8,64}',
|
||||
description => 'The short git revision from which this version was build.',
|
||||
},
|
||||
console => {
|
||||
|
@ -797,7 +797,7 @@ __PACKAGE__->register_method({
|
||||
|
||||
my @opt_pack = qw(
|
||||
ceph
|
||||
crtools
|
||||
criu
|
||||
gfs2-utils
|
||||
ksm-control-daemon
|
||||
ksmtuned
|
||||
|
@ -56,8 +56,6 @@ my $find_mon_ips = sub {
|
||||
|
||||
if (!scalar(@{$overwrite_ips})) { # auto-select one address for each public network
|
||||
for my $net (@{$public_nets}) {
|
||||
$net = PVE::JSONSchema::pve_verify_cidr($net);
|
||||
|
||||
my $allowed_ips = PVE::Network::get_local_ip_from_cidr($net);
|
||||
$allowed_ips = PVE::Network::unique_ips($allowed_ips);
|
||||
|
||||
@ -75,8 +73,6 @@ my $find_mon_ips = sub {
|
||||
my $allowed_list = [];
|
||||
|
||||
for my $net (@{$public_nets}) {
|
||||
$net = PVE::JSONSchema::pve_verify_cidr($net);
|
||||
|
||||
push @{$allowed_list}, @{PVE::Network::get_local_ip_from_cidr($net)};
|
||||
}
|
||||
|
||||
|
@ -17,6 +17,6 @@ clean:
|
||||
rm -rf *~
|
||||
|
||||
.PHONY: install
|
||||
install: ${PERLSOURCE}
|
||||
install -d ${PERLLIBDIR}/PVE/API2/Ceph
|
||||
install -m 0644 ${PERLSOURCE} ${PERLLIBDIR}/PVE/API2/Ceph
|
||||
install: $(PERLSOURCE)
|
||||
install -d $(PERLLIBDIR)/PVE/API2/Ceph
|
||||
install -m 0644 $(PERLSOURCE) $(PERLLIBDIR)/PVE/API2/Ceph
|
||||
|
@ -222,7 +222,10 @@ __PACKAGE__->register_method({
|
||||
items => {
|
||||
type => "object",
|
||||
properties => {
|
||||
id => { type => 'string' },
|
||||
id => {
|
||||
description => "Resource id.",
|
||||
type => 'string',
|
||||
},
|
||||
type => {
|
||||
description => "Resource type.",
|
||||
type => 'string',
|
||||
|
@ -15,6 +15,6 @@ clean:
|
||||
rm -rf *~
|
||||
|
||||
.PHONY: install
|
||||
install: ${PERLSOURCE}
|
||||
install -d ${PERLLIBDIR}/PVE/API2/Cluster
|
||||
install -m 0644 ${PERLSOURCE} ${PERLLIBDIR}/PVE/API2/Cluster
|
||||
install: $(PERLSOURCE)
|
||||
install -d $(PERLLIBDIR)/PVE/API2/Cluster
|
||||
install -m 0644 $(PERLSOURCE) $(PERLLIBDIR)/PVE/API2/Cluster
|
||||
|
@ -12,5 +12,5 @@ clean:
|
||||
|
||||
.PHONY: install
|
||||
install:
|
||||
install -d ${PERLLIBDIR}/PVE/API2/Hardware
|
||||
install -m 0644 ${PERLSOURCE} ${PERLLIBDIR}/PVE/API2/Hardware
|
||||
install -d $(PERLLIBDIR)/PVE/API2/Hardware
|
||||
install -m 0644 $(PERLSOURCE) $(PERLLIBDIR)/PVE/API2/Hardware
|
||||
|
@ -30,10 +30,10 @@ all:
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -rf *~
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
|
||||
.PHONY: install
|
||||
install: ${PERLSOURCE}
|
||||
install -d ${PERLLIBDIR}/PVE/API2
|
||||
install -m 0644 ${PERLSOURCE} ${PERLLIBDIR}/PVE/API2
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
install: $(PERLSOURCE)
|
||||
install -d $(PERLLIBDIR)/PVE/API2
|
||||
install -m 0644 $(PERLSOURCE) $(PERLLIBDIR)/PVE/API2
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
|
@ -663,13 +663,12 @@ __PACKAGE__->register_method({
|
||||
};
|
||||
if (-e '/usr/share/ifupdown2') {
|
||||
PVE::Tools::run_command(['/usr/sbin/ifreload', '-a'], errfunc => $err);
|
||||
if ($have_sdn) {
|
||||
PVE::Network::SDN::generate_controller_config(1);
|
||||
}
|
||||
} else {
|
||||
PVE::Tools::run_command(['systemctl', 'restart', 'network'], errfunc => $err);
|
||||
}
|
||||
|
||||
if ($have_sdn) {
|
||||
PVE::Network::SDN::generate_controller_config(1);
|
||||
}
|
||||
};
|
||||
return $rpcenv->fork_worker('srvreload', 'networking', $authuser, $worker);
|
||||
}});
|
||||
|
@ -17,6 +17,7 @@ use IO::File;
|
||||
use base qw(PVE::RESTHandler);
|
||||
|
||||
my $service_name_list = [
|
||||
'chrony',
|
||||
'corosync',
|
||||
'crond',
|
||||
'ksmtuned',
|
||||
|
@ -109,7 +109,7 @@ __PACKAGE__->register_method ({
|
||||
my $has_permission = $rpcenv->check($authuser, "/nodes/$node", ['Sys.Audit'], 1);
|
||||
|
||||
my $server_id = PVE::API2Tools::get_hwaddress();
|
||||
my $url = "https://www.proxmox.com/proxmox-ve/pricing";
|
||||
my $url = "https://www.proxmox.com/en/proxmox-virtual-environment/pricing";
|
||||
|
||||
my $info = read_etc_subscription();
|
||||
if (!$info) {
|
||||
|
@ -1,13 +1,22 @@
|
||||
include ../../defines.mk
|
||||
|
||||
SOURCES=vzdump.pm pvesubscription.pm pveceph.pm pveam.pm pvesr.pm pvenode.pm pvesh.pm pve6to7.pm
|
||||
SOURCES = \
|
||||
vzdump.pm \
|
||||
pvesubscription.pm \
|
||||
pveceph.pm \
|
||||
pveam.pm \
|
||||
pvesr.pm \
|
||||
pvenode.pm \
|
||||
pvesh.pm \
|
||||
pve6to7.pm \
|
||||
pve7to8.pm \
|
||||
|
||||
all:
|
||||
|
||||
.PHONY: install
|
||||
install: ${SOURCES}
|
||||
install -d -m 0755 ${PERLLIBDIR}/PVE/CLI
|
||||
for i in ${SOURCES}; do install -D -m 0644 $$i ${PERLLIBDIR}/PVE/CLI/$$i; done
|
||||
install: $(SOURCES)
|
||||
install -d -m 0755 $(PERLLIBDIR)/PVE/CLI
|
||||
for i in $(SOURCES); do install -D -m 0644 $$i $(PERLLIBDIR)/PVE/CLI/$$i; done
|
||||
|
||||
|
||||
clean:
|
||||
|
@ -172,7 +172,12 @@ sub check_pve_packages {
|
||||
my $upgraded = 0;
|
||||
|
||||
if ($maj > $min_pve_major) {
|
||||
log_pass("already upgraded to Proxmox VE " . ($min_pve_major + 1));
|
||||
my $pve_now = "". ($min_pve_major + 1);
|
||||
my $pve_next = "". ($min_pve_major + 2);
|
||||
log_pass("already upgraded to Proxmox VE ${pve_now}");
|
||||
log_warn("Proxmox VE ${pve_now} got superseeded by Proxmox VE ${pve_next}.\n"
|
||||
." Did you mean to use the pve${pve_now}to${pve_next} checker script?"
|
||||
);
|
||||
$upgraded = 1;
|
||||
} elsif ($maj >= $min_pve_major && $min >= $min_pve_minor && $pkgrel >= $min_pve_pkgrel) {
|
||||
log_pass("proxmox-ve package has version >= $min_pve_ver");
|
||||
|
1520
PVE/CLI/pve7to8.pm
Normal file
1520
PVE/CLI/pve7to8.pm
Normal file
File diff suppressed because it is too large
Load Diff
@ -11,6 +11,6 @@ clean:
|
||||
rm -rf *~
|
||||
|
||||
.PHONY: install
|
||||
install: ${PERLSOURCE}
|
||||
install -d ${PERLLIBDIR}/PVE/Ceph
|
||||
install -m 0644 ${PERLSOURCE} ${PERLLIBDIR}/PVE/Ceph
|
||||
install: $(PERLSOURCE)
|
||||
install -d $(PERLLIBDIR)/PVE/Ceph
|
||||
install -m 0644 $(PERLSOURCE) $(PERLLIBDIR)/PVE/Ceph
|
||||
|
@ -10,6 +10,6 @@ clean:
|
||||
rm -rf *~
|
||||
|
||||
.PHONY: install
|
||||
install: ${PERLSOURCE}
|
||||
install -d ${PERLLIBDIR}/PVE/Jobs
|
||||
install -m 0644 ${PERLSOURCE} ${PERLLIBDIR}/PVE/Jobs
|
||||
install: $(PERLSOURCE)
|
||||
install -d $(PERLLIBDIR)/PVE/Jobs
|
||||
install -m 0644 $(PERLSOURCE) $(PERLLIBDIR)/PVE/Jobs
|
||||
|
20
PVE/Makefile
20
PVE/Makefile
@ -16,24 +16,24 @@ PERLSOURCE = \
|
||||
Report.pm \
|
||||
VZDump.pm
|
||||
|
||||
all: pvecfg.pm ${SUBDIRS}
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i; done
|
||||
all: pvecfg.pm $(SUBDIRS)
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i; done
|
||||
|
||||
pvecfg.pm: pvecfg.pm.in
|
||||
sed -e s/@VERSION@/${VERSION}/ -e s/@PVERELEASE@/${PVERELEASE}/ -e s/@PACKAGE@/${PACKAGE}/ -e s/@REPOID@/${REPOID}/ $< >$@.tmp
|
||||
sed 's/@VERSION@/$(VERSION)/;s/@PVERELEASE@/$(PVERELEASE)/;s/@PACKAGE@/$(PACKAGE)/;s/@REPOID@/$(REPOID)/' $< >$@.tmp
|
||||
mv $@.tmp $@
|
||||
|
||||
%:
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
rm -rf *~ pvecfg.pm pvecfg.pm.tmp
|
||||
|
||||
.PHONY: install
|
||||
install: pvecfg.pm ${PERLSOURCE}
|
||||
install -d ${PERLLIBDIR}/PVE
|
||||
install -m 0644 pvecfg.pm ${PERLLIBDIR}/PVE/
|
||||
install -m 0644 ${PERLSOURCE} ${PERLLIBDIR}/PVE/
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
install: pvecfg.pm $(PERLSOURCE)
|
||||
install -d $(PERLLIBDIR)/PVE
|
||||
install -m 0644 pvecfg.pm $(PERLLIBDIR)/PVE/
|
||||
install -m 0644 $(PERLSOURCE) $(PERLLIBDIR)/PVE/
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
|
@ -29,6 +29,7 @@ my $init_report_cmds = sub {
|
||||
order => 10,
|
||||
cmds => [
|
||||
'hostname',
|
||||
'date -R',
|
||||
'pveversion --verbose',
|
||||
'cat /etc/hosts',
|
||||
'pvesubscription get',
|
||||
|
@ -5,8 +5,8 @@ SOURCES=pvestatd.pm pveproxy.pm pvedaemon.pm spiceproxy.pm pvescheduler.pm
|
||||
all:
|
||||
|
||||
.PHONY: install
|
||||
install: ${SOURCES}
|
||||
install -d -m 0755 ${PERLLIBDIR}/PVE/Service
|
||||
for i in ${SOURCES}; do install -D -m 0644 $$i ${PERLLIBDIR}/PVE/Service/$$i; done
|
||||
install: $(SOURCES)
|
||||
install -d -m 0755 $(PERLLIBDIR)/PVE/Service
|
||||
for i in $(SOURCES); do install -D -m 0644 $$i $(PERLLIBDIR)/PVE/Service/$$i; done
|
||||
|
||||
clean:
|
||||
|
@ -3,26 +3,25 @@ package PVE::Service::pveproxy;
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use PVE::SafeSyslog;
|
||||
use PVE::Daemon;
|
||||
use HTTP::Response;
|
||||
use Encode;
|
||||
use URI;
|
||||
use URI::QueryParam;
|
||||
use Data::Dumper;
|
||||
use PVE::Cluster;
|
||||
use PVE::DataCenterConfig;
|
||||
use PVE::APIServer::Utils;
|
||||
use PVE::API2;
|
||||
use PVE::APIServer::Formatter;
|
||||
use PVE::APIServer::Formatter::Standard;
|
||||
use PVE::APIServer::Formatter::HTML;
|
||||
use PVE::APIServer::AnyEvent;
|
||||
use PVE::HTTPServer;
|
||||
use PVE::pvecfg;
|
||||
|
||||
use Encode;
|
||||
use HTTP::Response;
|
||||
use Template;
|
||||
use URI::QueryParam;
|
||||
use URI;
|
||||
|
||||
use PVE::API2;
|
||||
use PVE::APIServer::AnyEvent;
|
||||
use PVE::APIServer::Formatter::HTML;
|
||||
use PVE::APIServer::Formatter::Standard;
|
||||
use PVE::APIServer::Formatter;
|
||||
use PVE::APIServer::Utils;
|
||||
use PVE::Cluster;
|
||||
use PVE::Daemon;
|
||||
use PVE::DataCenterConfig;
|
||||
use PVE::HTTPServer;
|
||||
use PVE::SafeSyslog;
|
||||
use PVE::pvecfg;
|
||||
use PVE::Tools;
|
||||
|
||||
use base qw(PVE::Daemon);
|
||||
@ -48,14 +47,15 @@ sub add_dirs {
|
||||
}
|
||||
|
||||
my $basedirs = {
|
||||
novnc => '/usr/share/novnc-pve',
|
||||
extjs => '/usr/share/javascript/extjs',
|
||||
manager => '/usr/share/pve-manager',
|
||||
i18n => '/usr/share/pve-i18n',
|
||||
docs => '/usr/share/pve-docs',
|
||||
extjs => '/usr/share/javascript/extjs',
|
||||
fontawesome => '/usr/share/fonts-font-awesome',
|
||||
xtermjs => '/usr/share/pve-xtermjs',
|
||||
i18n => '/usr/share/pve-i18n',
|
||||
manager => '/usr/share/pve-manager',
|
||||
novnc => '/usr/share/novnc-pve',
|
||||
sencha_touch => '/usr/share/javascript/sencha-touch',
|
||||
widgettoolkit => '/usr/share/javascript/proxmox-widget-toolkit',
|
||||
xtermjs => '/usr/share/pve-xtermjs',
|
||||
};
|
||||
|
||||
sub init {
|
||||
@ -74,21 +74,22 @@ sub init {
|
||||
|
||||
my $dirs = {};
|
||||
|
||||
add_dirs($dirs, '/pve2/locale/', "$basedirs->{i18n}/");
|
||||
add_dirs($dirs, '/pve2/touch/', "$basedirs->{manager}/touch/");
|
||||
add_dirs($dirs, '/pve2/ext6/', "$basedirs->{extjs}/");
|
||||
add_dirs($dirs, '/pve2/images/' => "$basedirs->{manager}/images/");
|
||||
add_dirs($dirs, '/pve2/css/' => "$basedirs->{manager}/css/");
|
||||
add_dirs($dirs, '/pve2/js/' => "$basedirs->{manager}/js/");
|
||||
add_dirs($dirs, '/pve2/fa/fonts/' => "$basedirs->{fontawesome}/fonts/");
|
||||
add_dirs($dirs, '/pve2/fa/css/' => "$basedirs->{fontawesome}/css/");
|
||||
add_dirs($dirs, '/novnc/' => "$basedirs->{novnc}/");
|
||||
add_dirs($dirs, '/pve-docs/' => "$basedirs->{docs}/");
|
||||
add_dirs($dirs, '/pve-docs/api-viewer/extjs/' => "$basedirs->{extjs}/");
|
||||
add_dirs($dirs, '/novnc/' => "$basedirs->{novnc}/");
|
||||
add_dirs($dirs, '/xtermjs/' => "$basedirs->{xtermjs}/");
|
||||
add_dirs($dirs, '/pwt/images/' => "$basedirs->{widgettoolkit}/images/");
|
||||
add_dirs($dirs, '/pve2/css/' => "$basedirs->{manager}/css/");
|
||||
add_dirs($dirs, '/pve2/ext6/', "$basedirs->{extjs}/");
|
||||
add_dirs($dirs, '/pve2/fa/css/' => "$basedirs->{fontawesome}/css/");
|
||||
add_dirs($dirs, '/pve2/fa/fonts/' => "$basedirs->{fontawesome}/fonts/");
|
||||
add_dirs($dirs, '/pve2/images/' => "$basedirs->{manager}/images/");
|
||||
add_dirs($dirs, '/pve2/js/' => "$basedirs->{manager}/js/");
|
||||
add_dirs($dirs, '/pve2/locale/', "$basedirs->{i18n}/");
|
||||
add_dirs($dirs, '/pve2/sencha-touch/', "$basedirs->{sencha_touch}/");
|
||||
add_dirs($dirs, '/pve2/touch/', "$basedirs->{manager}/touch/");
|
||||
add_dirs($dirs, '/pwt/css/' => "$basedirs->{widgettoolkit}/css/");
|
||||
add_dirs($dirs, '/pwt/images/' => "$basedirs->{widgettoolkit}/images/");
|
||||
add_dirs($dirs, '/pwt/themes/' => "$basedirs->{widgettoolkit}/themes/");
|
||||
add_dirs($dirs, '/xtermjs/' => "$basedirs->{xtermjs}/");
|
||||
|
||||
$self->{server_config} = {
|
||||
title => 'Proxmox VE API',
|
||||
@ -192,7 +193,7 @@ sub get_index {
|
||||
my $lang;
|
||||
my $username;
|
||||
my $token = 'null';
|
||||
my $theme = "";
|
||||
my $theme = "auto";
|
||||
|
||||
if (my $cookie = $r->header('Cookie')) {
|
||||
if (my $newlang = ($cookie =~ /(?:^|\s)PVELangCookie=([^;]*)/)[0]) {
|
||||
@ -215,42 +216,22 @@ sub get_index {
|
||||
}
|
||||
}
|
||||
|
||||
if ($theme eq "") {
|
||||
$theme = "auto"
|
||||
}
|
||||
|
||||
if (!$lang) {
|
||||
my $dc_conf = PVE::Cluster::cfs_read_file('datacenter.cfg');
|
||||
$lang = $dc_conf->{language} // 'en';
|
||||
}
|
||||
|
||||
$username = '' if !$username;
|
||||
|
||||
my $mobile = is_phone($r->header('User-Agent')) ? 1 : 0;
|
||||
|
||||
if (defined($args->{mobile})) {
|
||||
$mobile = $args->{mobile} ? 1 : 0;
|
||||
}
|
||||
my $mobile = (is_phone($r->header('User-Agent')) && (!defined($args->{mobile}) || $args->{mobile})) || $args->{mobile};
|
||||
|
||||
my $novnc = defined($args->{console}) && $args->{novnc};
|
||||
my $xtermjs = defined($args->{console}) && $args->{xtermjs};
|
||||
|
||||
my $page = '';
|
||||
my $template = Template->new({ABSOLUTE => 1});
|
||||
|
||||
my $langfile = 0;
|
||||
|
||||
if (-f "$basedirs->{i18n}/pve-lang-$lang.js") {
|
||||
$langfile = 1;
|
||||
}
|
||||
my $langfile = -f "$basedirs->{i18n}/pve-lang-$lang.js" ? 1 : 0;
|
||||
|
||||
my $version = PVE::pvecfg::version();
|
||||
|
||||
my $wtversionraw = PVE::Tools::file_read_firstline("$basedirs->{widgettoolkit}/proxmoxlib.js");
|
||||
my $wtversion;
|
||||
if ($wtversionraw =~ m|^// (.*)$|) {
|
||||
$wtversion = $1;
|
||||
};
|
||||
my $wtversion = $wtversionraw =~ m|^// (.*)$| ? $1 : '';
|
||||
|
||||
my $debug = $server->{debug};
|
||||
if (exists $args->{debug}) {
|
||||
@ -260,7 +241,7 @@ sub get_index {
|
||||
my $vars = {
|
||||
lang => $lang,
|
||||
langfile => $langfile,
|
||||
username => $username,
|
||||
username => $username || '',
|
||||
token => $token,
|
||||
console => $args->{console},
|
||||
nodename => $nodename,
|
||||
@ -281,8 +262,11 @@ sub get_index {
|
||||
$dir = "$basedirs->{manager}/touch";
|
||||
}
|
||||
|
||||
$template->process("$dir/index.html.tpl", $vars, \$page)
|
||||
|| die $template->error(), "\n";
|
||||
my $page = '';
|
||||
my $template = Template->new({ABSOLUTE => 1});
|
||||
|
||||
$template->process("$dir/index.html.tpl", $vars, \$page) || die $template->error(), "\n";
|
||||
|
||||
my $headers = HTTP::Headers->new(Content_Type => "text/html; charset=utf-8");
|
||||
my $resp = HTTP::Response->new(200, "OK", $headers, $page);
|
||||
|
||||
|
@ -12,6 +12,6 @@ clean:
|
||||
rm -rf *~
|
||||
|
||||
.PHONY: install
|
||||
install: ${PERLSOURCE}
|
||||
install -d ${PERLLIBDIR}/PVE/Status
|
||||
install -m 0644 ${PERLSOURCE} ${PERLLIBDIR}/PVE/Status
|
||||
install: $(PERLSOURCE)
|
||||
install -d $(PERLLIBDIR)/PVE/Status
|
||||
install -m 0644 $(PERLSOURCE) $(PERLLIBDIR)/PVE/Status
|
||||
|
@ -4,14 +4,15 @@ DOCDIR=/usr/share/doc/pve-manager/
|
||||
TRUSTED_KEYS= \
|
||||
proxmox-release-6.x.pubkey \
|
||||
proxmox-release-bullseye.pubkey \
|
||||
proxmox-release-bookworm.gpg \
|
||||
release@turnkeylinux.com.pubkey
|
||||
|
||||
all:
|
||||
|
||||
.PHONY: install
|
||||
install: aplinfo.dat trustedkeys.gpg
|
||||
install -D -m 0644 aplinfo.dat ${DESTDIR}${DOCDIR}/aplinfo.dat
|
||||
install -D -m 0644 trustedkeys.gpg ${DESTDIR}${DOCDIR}/trustedkeys.gpg
|
||||
install -D -m 0644 aplinfo.dat $(DESTDIR)$(DOCDIR)/aplinfo.dat
|
||||
install -D -m 0644 trustedkeys.gpg $(DESTDIR)$(DOCDIR)/trustedkeys.gpg
|
||||
|
||||
.PHONY: update
|
||||
update:
|
||||
@ -19,12 +20,10 @@ update:
|
||||
wget http://download.proxmox.com/images/aplinfo-pve-7.dat -O aplinfo.dat.tmp
|
||||
mv aplinfo.dat.tmp aplinfo.dat
|
||||
|
||||
%.gpg: %.pubkey
|
||||
gpg --dearmor -o $@ $<
|
||||
|
||||
trustedkeys.gpg: ${TRUSTED_KEYS:.pubkey=.gpg}
|
||||
cat $^ > $@
|
||||
trustedkeys.gpg: $(TRUSTED_KEYS)
|
||||
sq keyring join --binary -o $@.tmp *.pubkey proxmox-release-bookworm.gpg
|
||||
mv $@.tmp $@
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -rf *~ aplinfo.dat.gz aplinfo.dat.asc tempgpg *.gpg
|
||||
rm -rf *~ aplinfo.dat.gz aplinfo.dat.asc trustedkeys.gpg
|
||||
|
@ -30,32 +30,6 @@ sha512sum: 9b4561fad0de45943c0c46d9a075796533b0941c442cb70a5f9a323a601aba41f2e5e
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for almalinux 9 (20221108)
|
||||
|
||||
Package: alpine-3.14-default
|
||||
Version: 20210623
|
||||
Type: lxc
|
||||
OS: alpine
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/alpine-3.14-default_20210623_amd64.tar.xz
|
||||
md5sum: 06f638cc942c7965f5b5414300e01e60
|
||||
sha512sum: 87709566840d4ef5fe7bba63afce183f12c27e7499315d1729886ab0ca0c14599093b9da937037b86093c0ba15385d51b987f79a612150950e9e197757deeb37
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for alpine 3.14 (20210623)
|
||||
|
||||
Package: alpine-3.15-default
|
||||
Version: 20211202
|
||||
Type: lxc
|
||||
OS: alpine
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/alpine-3.15-default_20211202_amd64.tar.xz
|
||||
md5sum: 31fac55c59c899e71500e39ea4d868be
|
||||
sha512sum: 6fa966787de6f18fc502016cd3516bcac0a5de0dfa5e906aa08a1c0cc51b51b0df08d9efbe221e0914dbece295d1b32ccae14909a04fbfc263b8e0ecd4831491
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for alpine 3.15 (20211202)
|
||||
|
||||
Package: alpine-3.16-default
|
||||
Version: 20220622
|
||||
Type: lxc
|
||||
@ -82,16 +56,29 @@ sha512sum: 446185a5472c18cb7b60cb808e60730fd8fd438b0b94182f5317cddc78e9585224835
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for alpine 3.17 (20221129)
|
||||
|
||||
Package: alpine-3.18-default
|
||||
Version: 20230607
|
||||
Type: lxc
|
||||
OS: alpine
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/alpine-3.18-default_20230607_amd64.tar.xz
|
||||
md5sum: 298d21830b18f9d1fc98f6797bd36967
|
||||
sha512sum: f9d19b4a6d3c6201cf7a4624baf2d16ef08e7668adec0b7ea1a9c0ab8d854c8a9d11da48cc6f89ddb50a873bd339cfd4d76c402e8548f425469afba1a148479a
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for alpine 3.18 (20230607)
|
||||
|
||||
Package: archlinux-base
|
||||
Version: 20221111-1
|
||||
Version: 20230608-1
|
||||
Type: lxc
|
||||
OS: archlinux
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/archlinux-base_20221111-1_amd64.tar.zst
|
||||
md5sum: e83fea20d8975fe774c189ea0ec5e05a
|
||||
sha512sum: 354871fe963c1cc185a11b4688c658d8a4d172e73ee47d78503889720752ea5818092d72464c860e4b4d5daea9cee7c0850bcc8d7ea8904e9d1ae1c1b6bb5054
|
||||
Location: system/archlinux-base_20230608-1_amd64.tar.zst
|
||||
md5sum: 581d33c1c8b71aa72df47d84285eef8e
|
||||
sha512sum: 7f1ece6ded3d8571da8e0e20695e68391bec7585746632c6d555c8a8ecff3611fd87cf136c823d33d795e2c9adae9501190796a6d54c097c134afb965c97600f
|
||||
Infopage: https://www.archlinux.org
|
||||
Description: ArchLinux base image.
|
||||
ArchLinux template with the 'base' group and the 'openssh' package installed.
|
||||
@ -163,19 +150,33 @@ Description: Debian 10 Buster (standard)
|
||||
A small Debian Buster system including all standard packages.
|
||||
|
||||
Package: debian-11-standard
|
||||
Version: 11.3-1
|
||||
Version: 11.7-1
|
||||
Type: lxc
|
||||
OS: debian-11
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/debian-11-standard_11.3-1_amd64.tar.zst
|
||||
md5sum: 5a061ed422b8ef0a4de61abe56c6ce36
|
||||
sha512sum: da331993ba1a62a67ffff316dee361019491e48aa227ccb90db417095f7ff63c4c61ace3817573fc21567cd7a16f3dbd04c2966b21d1418864e037daec908143
|
||||
Location: system/debian-11-standard_11.7-1_amd64.tar.zst
|
||||
md5sum: d07069fe196e89ef70a546625507882a
|
||||
sha512sum: 973bb8ee260b5da8c02b023651370d53632ae0b838d878e5cbe38291ca2bcac9ab2d0ef80709e5e27865cfd48a67ff334ea1441d5744e3db372a1fcc84491557
|
||||
Infopage: https://pve.proxmox.com/wiki/Linux_Container#pct_supported_distributions
|
||||
Description: Debian 11 Bullseye (standard)
|
||||
A small Debian Bullseye system including all standard packages.
|
||||
|
||||
Package: debian-12-standard
|
||||
Version: 12.0-1
|
||||
Type: lxc
|
||||
OS: debian-12
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/debian-12-standard_12.0-1_amd64.tar.zst
|
||||
md5sum: 8afe6876381729eef9ce56fd5d2ac5d8
|
||||
sha512sum: 0cfbb0cd61fa9e5a11f83e2469e9175be79cab1f24385835715a9c29ea8e517d0526943cd6091b038e1f9d4bf57bfb30ddbc2802d9ada366f0b34019f940a3de
|
||||
Infopage: https://pve.proxmox.com/wiki/Linux_Container#pct_supported_distributions
|
||||
Description: Debian 12 Bookworm (standard)
|
||||
A small Debian Bullseye system including all standard packages.
|
||||
|
||||
Package: devuan-3.0-standard
|
||||
Version: 3.0
|
||||
Type: lxc
|
||||
@ -204,32 +205,6 @@ Infopage: https://devuan.org
|
||||
Description: Devuan 4.0 (standard)
|
||||
A small Devuan Chimaera system including a minimal set of essential packages.
|
||||
|
||||
Package: fedora-35-default
|
||||
Version: 20211111
|
||||
Type: lxc
|
||||
OS: fedora
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/fedora-35-default_20211111_amd64.tar.xz
|
||||
md5sum: 11bb241828ebba4bef8a4f12ae4fe0d5
|
||||
sha512sum: ddc3e4fbedeefb75e15098feddc2132242921eae52ff39b196dca2adc2e056e6fa88b39e38ac63d63f0806b1c10f681ad75bcf17387aab903b6770e62addcd8d
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for fedora 35 (20211111)
|
||||
|
||||
Package: fedora-36-default
|
||||
Version: 20220622
|
||||
Type: lxc
|
||||
OS: fedora
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/fedora-36-default_20220622_amd64.tar.xz
|
||||
md5sum: f799a34c2bb3a9e5a39fa4b16f503dbd
|
||||
sha512sum: 0fe7d94bea81011aeacc13e820efa107feb6c11384335367d199d28f00e610010945569733873d31e11c0e32f6fb8384e09563c2f26b096d95d072d68fb68e9a
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for fedora 36 (20220622)
|
||||
|
||||
Package: fedora-37-default
|
||||
Version: 20221119
|
||||
Type: lxc
|
||||
@ -243,6 +218,19 @@ sha512sum: b12d0bfd6fcfbb33c3b896a5a9c2bc5547817f69df2e72c8ed7d318b56412b550a8b9
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for fedora 37 (20221119)
|
||||
|
||||
Package: fedora-38-default
|
||||
Version: 20230607
|
||||
Type: lxc
|
||||
OS: fedora
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/fedora-38-default_20230607_amd64.tar.xz
|
||||
md5sum: 45bbf8c641320aa91f2c8cf52a5280cc
|
||||
sha512sum: 54328a3338ca9657d298a8a5d2ca15fe76f66fd407296d9e3e1c236ee60ea075d3406c175fdb46fe5c29e664224f2ce33bfe8cd1f634b7ea08d0183609d5e93c
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for fedora 38 (20230607)
|
||||
|
||||
Package: gentoo-current-openrc
|
||||
Version: 20220622
|
||||
Type: lxc
|
||||
@ -269,18 +257,32 @@ sha512sum: 8089309652a0db23ddff826d1e343e79c6eccb7b615fb309e0a6f6f1983ea697aa940
|
||||
Infopage: https://linuxcontainers.org
|
||||
Description: LXC default image for opensuse 15.4 (20221109)
|
||||
|
||||
Package: proxmox-mailgateway-7.2-standard
|
||||
Version: 7.2-1
|
||||
Package: proxmox-mailgateway-7.3-standard
|
||||
Version: 7.3-1
|
||||
Type: lxc
|
||||
OS: debian-11
|
||||
Section: mail
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: mail/proxmox-mailgateway-7.2-standard_7.2-1_amd64.tar.gz
|
||||
md5sum: a38d4284fc91d4d3cf2a324a702fd938
|
||||
sha512sum: d2ee3dba238d3b583e92f1b944cd7720fb4e79fcbf11902b1833700ebbe53b25093e100b66c240a5c55bbfb5e34187930455537dd400f7daa1c0ff26206995bf
|
||||
Location: mail/proxmox-mailgateway-7.3-standard_7.3-1_amd64.tar.zst
|
||||
md5sum: 6c130003f9880ae66dca0603d7b7ca87
|
||||
sha512sum: 2fdf1dc24306bbaa2ef9a0f322416ca15b97b7d19f84b83743c7afc896095c398241fbc2eb41a33a69f3f275ce4c4cb6425edc5538831b4650d39a5e44fdbc25
|
||||
Infopage: https://www.proxmox.com/de/proxmox-mail-gateway
|
||||
Description: Proxmox Mailgateway 7.2
|
||||
Description: Proxmox Mailgateway 7.3
|
||||
A full featured mail proxy for spam and virus filtering, optimized for container environment.
|
||||
|
||||
Package: proxmox-mailgateway-8.0-standard
|
||||
Version: 8.0-1
|
||||
Type: lxc
|
||||
OS: debian-12
|
||||
Section: mail
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: mail/proxmox-mailgateway-8.0-standard_8.0-1_amd64.tar.zst
|
||||
md5sum: 7d321e5dfc6e1005231586d1871e3625
|
||||
sha512sum: be5efcb8ee97f2bb1c638360191eda19f49e2063acb88da55c948c90c091063972cc9ea29e6aeaa4a85733e0fb2c99ea905d665ac693cb2bf06b091c4baf781f
|
||||
Infopage: https://www.proxmox.com/de/proxmox-mail-gateway
|
||||
Description: Proxmox Mailgateway 8.0
|
||||
A full featured mail proxy for spam and virus filtering, optimized for container environment.
|
||||
|
||||
Package: rockylinux-8-default
|
||||
@ -364,3 +366,17 @@ sha512sum: be2a5f3e749e8958fa8487f47aa67638d18c29d26c218cea289afc44923eb3efb0ef1
|
||||
Infopage: https://pve.proxmox.com/wiki/Linux_Container#pct_supported_distributions
|
||||
Description: Ubuntu 22.10 Kinetic (standard)
|
||||
A small Ubuntu 22.10 Kinetic Kudu system including all standard packages.
|
||||
|
||||
Package: ubuntu-23.04-standard
|
||||
Version: 23.04-1
|
||||
Type: lxc
|
||||
OS: ubuntu-23.04
|
||||
Section: system
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
Architecture: amd64
|
||||
Location: system/ubuntu-23.04-standard_23.04-1_amd64.tar.zst
|
||||
md5sum: 5dee55750bd72e210be6603e3b87005b
|
||||
sha512sum: 6c7d916cc76865d5984b6b41e3d45426071967059ecc0a5d10029d2706cca0ea96a3c4f4dfcede08e7a86f73b9dfbd3d07ac86ee380b0f12be6c35e486033249
|
||||
Infopage: https://pve.proxmox.com/wiki/Linux_Container#pct_supported_distributions
|
||||
Description: Ubuntu 23.04 Lunar (standard)
|
||||
A small Ubuntu 23.04 Lunar Lobster system including all standard packages.
|
||||
|
BIN
aplinfo/proxmox-release-bookworm.gpg
Normal file
BIN
aplinfo/proxmox-release-bookworm.gpg
Normal file
Binary file not shown.
90
bin/Makefile
90
bin/Makefile
@ -1,17 +1,24 @@
|
||||
include ../defines.mk
|
||||
|
||||
# this requires package pve-doc-generator
|
||||
export NOVIEW=1
|
||||
|
||||
PERL_DOC_INC_DIRS=..
|
||||
include /usr/share/pve-doc-generator/pve-doc-generator.mk
|
||||
-include /usr/share/pve-doc-generator/pve-doc-generator.mk
|
||||
|
||||
SERVICES = pvestatd pveproxy pvedaemon spiceproxy pvescheduler
|
||||
CLITOOLS = vzdump pvesubscription pveceph pveam pvesr pvenode pvesh pve6to7
|
||||
CLITOOLS = \
|
||||
vzdump \
|
||||
pvesubscription \
|
||||
pveceph \
|
||||
pveam \
|
||||
pvesr \
|
||||
pvenode \
|
||||
pvesh \
|
||||
pve6to7 \
|
||||
pve7to8 \
|
||||
|
||||
|
||||
SCRIPTS = \
|
||||
${SERVICES} \
|
||||
${CLITOOLS} \
|
||||
$(SERVICES) \
|
||||
$(CLITOOLS) \
|
||||
pvebanner \
|
||||
pveversion \
|
||||
pveupgrade \
|
||||
@ -19,28 +26,28 @@ SCRIPTS = \
|
||||
pveperf \
|
||||
pvereport
|
||||
|
||||
SERVICE_MANS = $(addsuffix .8, ${SERVICES})
|
||||
SERVICE_MANS = $(addsuffix .8, $(SERVICES))
|
||||
|
||||
CLI_MANS = \
|
||||
$(addsuffix .1, ${CLITOOLS}) \
|
||||
$(addsuffix .1, $(CLITOOLS)) \
|
||||
pveversion.1 \
|
||||
pveupgrade.1 \
|
||||
pveperf.1 \
|
||||
pvereport.1 \
|
||||
|
||||
BASH_COMPLETIONS = \
|
||||
$(addsuffix .service-bash-completion, ${SERVICES}) \
|
||||
$(addsuffix .bash-completion, ${CLITOOLS}) \
|
||||
$(addsuffix .service-bash-completion, $(SERVICES)) \
|
||||
$(addsuffix .bash-completion, $(CLITOOLS)) \
|
||||
|
||||
ZSH_COMPLETIONS = \
|
||||
$(addsuffix .service-zsh-completion, ${SERVICES}) \
|
||||
$(addsuffix .zsh-completion, ${CLITOOLS}) \
|
||||
$(addsuffix .service-zsh-completion, $(SERVICES)) \
|
||||
$(addsuffix .zsh-completion, $(CLITOOLS)) \
|
||||
|
||||
all: ${SERVICE_MANS} ${CLI_MANS}
|
||||
all: $(SERVICE_MANS) $(CLI_MANS)
|
||||
|
||||
%.1: %.1.pod
|
||||
rm -f $@
|
||||
cat $<|pod2man -n $* -s 1 -r ${VERSION} -c"Proxmox Documentation" - >$@.tmp
|
||||
cat $<|pod2man -n $* -s 1 -r $(VERSION) -c"Proxmox Documentation" - >$@.tmp
|
||||
mv $@.tmp $@
|
||||
|
||||
%.1.pod:
|
||||
@ -48,36 +55,47 @@ all: ${SERVICE_MANS} ${CLI_MANS}
|
||||
mv $@.tmp $@
|
||||
|
||||
pve6to7.1:
|
||||
printf ".TH PVE6TO7 1\n.SH NAME\npve6to7 \- Proxmox VE upgrade checker script for 6.4 to 7.x\n" > $@
|
||||
printf ".SH SYNOPSIS\npve6to7 [--full]\n" >> $@
|
||||
printf ".TH PVE6TO7 1\n.SH NAME\npve6to7 \- Proxmox VE upgrade checker script for 6.4 to 7.x\n" > $@.tmp
|
||||
printf ".SH NOTE\npve6to7 is for the previous upgrade, from Proxmox VE 6 to 7, but there's a\
|
||||
new Proxmox VE 8 available, see the 'pve7to8' tool.\n" >> $@.tmp
|
||||
printf ".SH SYNOPSIS\npve6to7 [--full]\n" >> $@.tmp
|
||||
mv $@.tmp $@
|
||||
|
||||
pve7to8.1:
|
||||
printf ".TH PVE7TO8 1\n.SH NAME\npve7to8 \- Proxmox VE upgrade checker script for 7.4+ to current 8.x\n" > $@.tmp
|
||||
printf ".SH DESCRIPTION\nThis tool will help you to detect common pitfalls and misconfguration\
|
||||
before, and during the upgrade of a Proxmox VE system\n" >> $@.tmp
|
||||
printf "Any failure must be addressed before the upgrade, and any waring must be addressed, \
|
||||
or at least carefully evaluated, if a false-positive is suspected\n" >> $@.tmp
|
||||
printf ".SH SYNOPSIS\npve7to8 [--full]\n" >> $@.tmp
|
||||
mv $@.tmp $@
|
||||
|
||||
pveversion.1.pod: pveversion
|
||||
pveupgrade.1.pod: pveupgrade
|
||||
pvereport.1.pod: pvereport
|
||||
|
||||
.PHONY: check
|
||||
check: $(addsuffix .service-api-verified, ${SERVICES}) $(addsuffix .api-verified, ${CLITOOLS})
|
||||
check: $(addsuffix .service-api-verified, $(SERVICES)) $(addsuffix .api-verified, $(CLITOOLS))
|
||||
rm -f *.service-api-verified *.api-verified
|
||||
|
||||
.PHONY: install
|
||||
install: ${SCRIPTS} ${CLI_MANS} ${SERVICE_MANS} ${BASH_COMPLETIONS} ${ZSH_COMPLETIONS}
|
||||
install -d ${BINDIR}
|
||||
install -m 0755 ${SCRIPTS} ${BINDIR}
|
||||
install -d ${USRSHARE}/helpers
|
||||
install -m 0755 pve-startall-delay ${USRSHARE}/helpers
|
||||
install -d ${MAN1DIR}
|
||||
install -m 0644 ${CLI_MANS} ${MAN1DIR}
|
||||
install -d ${MAN8DIR}
|
||||
install -m 0644 ${SERVICE_MANS} ${MAN8DIR}
|
||||
for i in ${CLITOOLS}; do install -m 0644 -D $$i.bash-completion ${BASHCOMPLDIR}/$$i; done
|
||||
for i in ${SERVICES}; do install -m 0644 -D $$i.service-bash-completion ${BASHCOMPLDIR}/$$i; done
|
||||
for i in ${CLITOOLS}; do install -m 0644 -D $$i.zsh-completion ${ZSHCOMPLDIR}/_$$i; done
|
||||
for i in ${SERVICES}; do install -m 0644 -D $$i.service-zsh-completion ${ZSHCOMPLDIR}/_$$i; done
|
||||
install: $(SCRIPTS) $(CLI_MANS) $(SERVICE_MANS) $(BASH_COMPLETIONS) $(ZSH_COMPLETIONS)
|
||||
install -d $(BINDIR)
|
||||
install -m 0755 $(SCRIPTS) $(BINDIR)
|
||||
install -d $(USRSHARE)/helpers
|
||||
install -m 0755 pve-startall-delay $(USRSHARE)/helpers
|
||||
install -d $(MAN1DIR)
|
||||
install -m 0644 $(CLI_MANS) $(MAN1DIR)
|
||||
install -d $(MAN8DIR)
|
||||
install -m 0644 $(SERVICE_MANS) $(MAN8DIR)
|
||||
for i in $(CLITOOLS); do install -m 0644 -D $$i.bash-completion $(BASHCOMPLDIR)/$$i; done
|
||||
for i in $(SERVICES); do install -m 0644 -D $$i.service-bash-completion $(BASHCOMPLDIR)/$$i; done
|
||||
for i in $(CLITOOLS); do install -m 0644 -D $$i.zsh-completion $(ZSHCOMPLDIR)/_$$i; done
|
||||
for i in $(SERVICES); do install -m 0644 -D $$i.service-zsh-completion $(ZSHCOMPLDIR)/_$$i; done
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
make cleanup-docgen
|
||||
rm -rf *~ *.tmp ${CLI_MANS} ${SERVICE_MANS} *.1.pod *.8.pod \
|
||||
*.bash-completion *.service-bash-completion \
|
||||
*.zsh-completion *.service-zsh-completion \
|
||||
*.api-verified *.service-api-verified
|
||||
rm -f *.xml.tmp *.1 *.5 *.8 *{synopsis,opts}.adoc docinfo.xml *.tmp
|
||||
rm -f *~ *.tmp $(CLI_MANS) $(SERVICE_MANS) *.1.pod *.8.pod
|
||||
rm -f *.bash-completion *.service-bash-completion *.zsh-completion *.service-zsh-completion
|
||||
rm -f *.api-verified *.service-api-verified
|
||||
|
8
bin/pve7to8
Executable file
8
bin/pve7to8
Executable file
@ -0,0 +1,8 @@
|
||||
#!/usr/bin/perl
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use PVE::CLI::pve7to8;
|
||||
|
||||
PVE::CLI::pve7to8->run_cli_handler();
|
@ -2,6 +2,7 @@
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use PVE::Report;
|
||||
|
||||
($> == 0 ) || die "please run as root\n";
|
||||
|
@ -7,12 +7,12 @@ country.dat: country.pl
|
||||
|
||||
.PHONY: install
|
||||
install: country.dat vzdump.conf pve-sources.list pve-initramfs.conf pve-blacklist.conf pve.logrotate
|
||||
install -D -m 0644 pve.logrotate ${DESTDIR}/etc/logrotate.d/pve
|
||||
install -D -m 0644 pve-sources.list ${DESTDIR}/etc/apt/sources.list.d/pve-enterprise.list
|
||||
install -D -m 0644 pve-blacklist.conf ${DESTDIR}/etc/modprobe.d/pve-blacklist.conf
|
||||
install -D -m 0644 vzdump.conf ${DESTDIR}/etc/vzdump.conf
|
||||
install -D -m 0644 pve-initramfs.conf ${DESTDIR}/etc/initramfs-tools/conf.d/pve-initramfs.conf
|
||||
install -D -m 0644 country.dat ${DESTDIR}/usr/share/${PACKAGE}/country.dat
|
||||
install -D -m 0644 pve.logrotate $(DESTDIR)/etc/logrotate.d/pve
|
||||
install -D -m 0644 pve-sources.list $(DESTDIR)/etc/apt/sources.list.d/pve-enterprise.list
|
||||
install -D -m 0644 pve-blacklist.conf $(DESTDIR)/etc/modprobe.d/pve-blacklist.conf
|
||||
install -D -m 0644 vzdump.conf $(DESTDIR)/etc/vzdump.conf
|
||||
install -D -m 0644 pve-initramfs.conf $(DESTDIR)/etc/initramfs-tools/conf.d/pve-initramfs.conf
|
||||
install -D -m 0644 country.dat $(DESTDIR)/usr/share/$(PACKAGE)/country.dat
|
||||
|
||||
clean:
|
||||
rm -f country.dat
|
||||
|
@ -1,4 +1,4 @@
|
||||
# This file contains a list of modules which are not supported by Proxmox VE
|
||||
|
||||
# nidiafb see bugreport https://bugzilla.proxmox.com/show_bug.cgi?id=701
|
||||
# nvidiafb see bugreport https://bugzilla.proxmox.com/show_bug.cgi?id=701
|
||||
blacklist nvidiafb
|
||||
|
157
debian/changelog
vendored
157
debian/changelog
vendored
@ -1,3 +1,160 @@
|
||||
pve-manager (7.4-17) bullseye; urgency=medium
|
||||
|
||||
* pve7to8:
|
||||
- fix check for ceph's global "noout" flag
|
||||
- adapt unified cgroupv2 check to the change of path where system is
|
||||
located in Fedora 38
|
||||
- add check for DKMS modules, as they are a frequent cause of issues on
|
||||
upgrade
|
||||
|
||||
* ui: vm selector: gracefully handle empty IDs in setting-value function
|
||||
|
||||
* update external links to www.proxmox.com
|
||||
|
||||
* update shipped appliance index
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 02 Oct 2023 08:01:34 +0200
|
||||
|
||||
pve-manager (7.4-16) bullseye; urgency=medium
|
||||
|
||||
* pve7to8: add checks for mismatched or strange repos
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 03 Jul 2023 13:12:20 +0200
|
||||
|
||||
pve-manager (7.4-15) bullseye; urgency=medium
|
||||
|
||||
* pve7to8: content-dirs check: skip paths that cannot be resolved
|
||||
|
||||
* pve7to8: remove outdated warning about retention
|
||||
|
||||
* pve7to8: avoid confusing warning about required setting 'storage' for
|
||||
vzdump
|
||||
|
||||
* pve7to8: enable ceph noout check before upgrade
|
||||
|
||||
* pve7to8: add check for systemd-boot presence where needed
|
||||
|
||||
* update shipped aplliance info index
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Wed, 21 Jun 2023 20:04:08 +0200
|
||||
|
||||
pve-manager (7.4-14) bullseye; urgency=medium
|
||||
|
||||
* pve7to8:
|
||||
- make check for correct running kernel more resilient
|
||||
- improve systemd unified cgroupv2 support check
|
||||
- add check for nvidia-vgpu-mgr, currently not compatible with the 6.2
|
||||
kernel
|
||||
- add check for permissions that are affected of dropping the
|
||||
'Permissions.Modify' privilege from 'PVEAdmin' and 'PVESysAdmin'
|
||||
built-in roles. Only 'Administrator', the most powerful built-in role
|
||||
after `root@pam`, will have the 'Permissions.Modify' privilege in the
|
||||
next major release, Proxmox VE 8.
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Wed, 14 Jun 2023 10:54:33 +0200
|
||||
|
||||
pve-manager (7.4-13) bullseye; urgency=medium
|
||||
|
||||
* aplinfo: ensure keyring is in binary format for GPG t compatibility
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Fri, 09 Jun 2023 11:42:05 +0200
|
||||
|
||||
pve-manager (7.4-12) bullseye; urgency=medium
|
||||
|
||||
* pve7to8: check if LXCFS is running with FUSE3 after upgrade
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Thu, 08 Jun 2023 13:00:23 +0200
|
||||
|
||||
pve-manager (7.4-11) bullseye; urgency=medium
|
||||
|
||||
* pve7to8:
|
||||
- warn if storage uses a directory for multiple content types
|
||||
- fix some typos
|
||||
- check for custom role ID clashes with "PVE" namespace
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Thu, 08 Jun 2023 09:48:55 +0200
|
||||
|
||||
pve-manager (7.4-9) bullseye; urgency=medium
|
||||
|
||||
* pve7to8:
|
||||
- cope with native version of proxmox-ve package
|
||||
- ceph version check: ignore commit hash
|
||||
|
||||
* api subscription: ensure apt-auth access to new ceph enterprise repo, if
|
||||
one wants to switch directly to that on (future) upgrade to Proxmox VE 8.
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 05 Jun 2023 19:22:38 +0200
|
||||
|
||||
pve-manager (7.4-8) bullseye; urgency=medium
|
||||
|
||||
* pve7to8:
|
||||
- improve log message for missing kernel reboot
|
||||
- differ running kernel message depending on being at pre and
|
||||
post upgrade
|
||||
- output failures in bold
|
||||
- add minimal ceph version check for hyper-converged setups
|
||||
- drop outdated apt security repo format change check
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Wed, 31 May 2023 17:51:46 +0200
|
||||
|
||||
pve-manager (7.4-6) bullseye; urgency=medium
|
||||
|
||||
* aplinfo: add bookworm release key to trusted ones
|
||||
|
||||
* build system improvements
|
||||
|
||||
* do not depend on obsolete lsb-base package
|
||||
|
||||
* copy over pve6to7 for new pve7to8 upgrade checker script
|
||||
|
||||
* pve7to8:
|
||||
- ensure pvescheduler.service is running OK
|
||||
- update check for free space to >= 5 GB
|
||||
- avoid scary colors for warn and fail if their counters are zero
|
||||
- check for active and known-OK time-daemon (NTP) unit
|
||||
|
||||
* pve6to7: add hint that there's a newer upgrade possible
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Wed, 31 May 2023 11:46:10 +0200
|
||||
|
||||
pve-manager (7.4-4) bullseye; urgency=medium
|
||||
|
||||
* pvereport: add `date -R` to general system info section
|
||||
|
||||
* api: description for 'id' property in /cluster/resources
|
||||
|
||||
* api: ceph: mon create: remove superfluous verification call
|
||||
|
||||
* fix #4627: ui: backup edit: don't deselect all guests on load
|
||||
|
||||
* ui: ceph install check: avoid setting nodename to localhost so that the
|
||||
check actually goes to the currently selected node, not the one we loaded
|
||||
the Proxmox VE Web UI from.
|
||||
|
||||
* ui: enable gettext localisation for more user exposed strings
|
||||
|
||||
* ui: clone: validate that the name of the clone is a valid FQDN
|
||||
|
||||
* drop local hosted sencha-touch source, depend on new libjs-sencha-touch
|
||||
|
||||
* mobile ui: adhere debug flag when loading sencha touch, making the initial
|
||||
load much more efficient by default
|
||||
|
||||
* mobile ui: statically import widget toolkit t o avoid breakage of code
|
||||
written for the ExtJS frame work and not the somewhat similar Sencha Touch
|
||||
framework
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Sun, 28 May 2023 19:54:09 +0200
|
||||
|
||||
pve-manager (7.4-3) bullseye; urgency=medium
|
||||
|
||||
* ui: ceph osd: fix call to reload in wrong this context causing a potential
|
||||
exception when closing the ceph install wizard
|
||||
|
||||
* ui: ceph: unmask container after we finished the ceph install
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Wed, 22 Mar 2023 15:33:38 +0100
|
||||
|
||||
pve-manager (7.4-2) bullseye; urgency=medium
|
||||
|
||||
* ui: lvm-thin: don't add nodeselector/enable multiple times in edit
|
||||
|
12
debian/control
vendored
12
debian/control
vendored
@ -12,7 +12,7 @@ Build-Depends: debhelper (>= 12~),
|
||||
libpve-cluster-api-perl,
|
||||
libpve-cluster-perl (>= 6.1-6),
|
||||
libpve-common-perl (>= 7.2-6),
|
||||
libpve-guest-common-perl (>= 4.2-1),
|
||||
libpve-guest-common-perl (>= 4.2),
|
||||
libpve-http-server-perl (>= 2.0-12),
|
||||
libpve-rs-perl (>= 0.7.1),
|
||||
libpve-storage-perl (>= 6.3-2),
|
||||
@ -23,16 +23,18 @@ Build-Depends: debhelper (>= 12~),
|
||||
pve-cluster,
|
||||
pve-container,
|
||||
pve-doc-generator (>= 7.2-3),
|
||||
pve-eslint (>= 7.28.0-1),
|
||||
pve-eslint (>= 7.28.0),
|
||||
qemu-server (>= 6.0-15),
|
||||
sq,
|
||||
unzip,
|
||||
Standards-Version: 4.6.1
|
||||
Maintainer: Proxmox Support Team <support@proxmox.com>
|
||||
|
||||
Package: pve-manager
|
||||
Section: admin
|
||||
Priority: optional
|
||||
Architecture: any
|
||||
Depends: apt-transport-https | apt (>= 1.5~),
|
||||
Depends: apt (>= 1.5~),
|
||||
ca-certificates,
|
||||
cstream,
|
||||
dtach,
|
||||
@ -41,12 +43,12 @@ Depends: apt-transport-https | apt (>= 1.5~),
|
||||
hdparm,
|
||||
ifupdown2 (>= 2.0.1-1+pve8) | ifenslave (>= 2.6),
|
||||
libapt-pkg-perl,
|
||||
libc6 (>= 2.14),
|
||||
libcrypt-ssleay-perl,
|
||||
libfile-readbackwards-perl,
|
||||
libfilesys-df-perl,
|
||||
libjs-extjs (>= 7.0.0),
|
||||
libjs-qrcodejs (>= 1.20201119),
|
||||
libjs-sencha-touch,
|
||||
libjson-perl,
|
||||
liblwp-protocol-https-perl,
|
||||
libnet-dns-perl,
|
||||
@ -68,7 +70,6 @@ Depends: apt-transport-https | apt (>= 1.5~),
|
||||
libuuid-perl,
|
||||
libwww-perl (>= 6.04-1),
|
||||
logrotate,
|
||||
lsb-base,
|
||||
lzop,
|
||||
zstd,
|
||||
novnc-pve (>= 1.2.0-2~),
|
||||
@ -93,6 +94,7 @@ Depends: apt-transport-https | apt (>= 1.5~),
|
||||
wget,
|
||||
${misc:Depends},
|
||||
${perl:Depends},
|
||||
${shlibs:Depends}
|
||||
Recommends: proxmox-offline-mirror-helper
|
||||
Suggests: libpve-network-perl (>= 0.5-1)
|
||||
Conflicts: vlan,
|
||||
|
2
debian/postinst
vendored
2
debian/postinst
vendored
@ -228,7 +228,7 @@ case "$1" in
|
||||
done
|
||||
fi
|
||||
|
||||
if test ! -e /proxmox_install_mode && test -n "$2" && dpkg --compare-versions "$2" 'lt' '7.2.11~'; then
|
||||
if test ! -e /proxmox_install_mode && test -n "$2" && dpkg --compare-versions "$2" 'lt' '7.2-11~'; then
|
||||
if test -e /etc/apt/auth.conf ; then
|
||||
migrate_apt_auth_conf
|
||||
fi
|
||||
|
@ -4,10 +4,10 @@ all:
|
||||
|
||||
.PHONY: install
|
||||
install: mtu bridgevlan bridgevlanport vlan vlan-down
|
||||
install -D -m 0755 mtu ${DESTDIR}/etc/network/if-up.d/mtu
|
||||
install -D -m 0755 bridgevlan ${DESTDIR}/etc/network/if-up.d/bridgevlan
|
||||
install -D -m 0755 bridgevlanport ${DESTDIR}/etc/network/if-up.d/bridgevlanport
|
||||
install -D -m 0755 vlan ${DESTDIR}/etc/network/if-pre-up.d/vlan
|
||||
install -D -m 0755 vlan-down ${DESTDIR}/etc/network/if-post-down.d/vlan
|
||||
install -D -m 0755 mtu $(DESTDIR)/etc/network/if-up.d/mtu
|
||||
install -D -m 0755 bridgevlan $(DESTDIR)/etc/network/if-up.d/bridgevlan
|
||||
install -D -m 0755 bridgevlanport $(DESTDIR)/etc/network/if-up.d/bridgevlanport
|
||||
install -D -m 0755 vlan $(DESTDIR)/etc/network/if-pre-up.d/vlan
|
||||
install -D -m 0755 vlan-down $(DESTDIR)/etc/network/if-post-down.d/vlan
|
||||
|
||||
clean:
|
||||
|
@ -16,20 +16,20 @@ SERVICES= \
|
||||
pvescheduler.service
|
||||
|
||||
.PHONY: install
|
||||
install: ${SERVICES}
|
||||
install -d ${SERVICEDIR}
|
||||
install -m 0644 ${SERVICES} ${SERVICEDIR}
|
||||
install -d ${SERVICEDIR}/ceph-mon@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf ${SERVICEDIR}/ceph-mon@.service.d
|
||||
install -d ${SERVICEDIR}/ceph-mgr@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf ${SERVICEDIR}/ceph-mgr@.service.d
|
||||
install -d ${SERVICEDIR}/ceph-osd@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf ${SERVICEDIR}/ceph-osd@.service.d
|
||||
install -d ${SERVICEDIR}/ceph-volume@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf ${SERVICEDIR}/ceph-volume@.service.d
|
||||
install -d ${SERVICEDIR}/ceph-mds@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf ${SERVICEDIR}/ceph-mds@.service.d
|
||||
install -d ${DESTDIR}/usr/share/doc/${PACKAGE}/examples/
|
||||
install: $(SERVICES)
|
||||
install -d $(SERVICEDIR)
|
||||
install -m 0644 $(SERVICES) $(SERVICEDIR)
|
||||
install -d $(SERVICEDIR)/ceph-mon@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf $(SERVICEDIR)/ceph-mon@.service.d
|
||||
install -d $(SERVICEDIR)/ceph-mgr@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf $(SERVICEDIR)/ceph-mgr@.service.d
|
||||
install -d $(SERVICEDIR)/ceph-osd@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf $(SERVICEDIR)/ceph-osd@.service.d
|
||||
install -d $(SERVICEDIR)/ceph-volume@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf $(SERVICEDIR)/ceph-volume@.service.d
|
||||
install -d $(SERVICEDIR)/ceph-mds@.service.d
|
||||
install -m 0644 ceph-after-pve-cluster.conf $(SERVICEDIR)/ceph-mds@.service.d
|
||||
install -d $(DESTDIR)/usr/share/doc/$(PACKAGE)/examples/
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
14
www/Makefile
14
www/Makefile
@ -1,19 +1,19 @@
|
||||
include ../defines.mk
|
||||
SUBDIRS = images css manager6 touch mobile
|
||||
SUBDIRS = images css manager6 mobile
|
||||
|
||||
all:
|
||||
|
||||
.PHONY: install
|
||||
install:
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
install -m 0644 index.html.tpl ${WWWBASEDIR}
|
||||
install -d ${WWWJSDIR}
|
||||
install -m 0644 u2f-api.js ${WWWJSDIR}
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
install -m 0644 index.html.tpl $(WWWBASEDIR)
|
||||
install -d $(WWWJSDIR)
|
||||
install -m 0644 u2f-api.js $(WWWJSDIR)
|
||||
|
||||
.PHONY: check
|
||||
check:
|
||||
${MAKE} -C manager6 $@
|
||||
$(MAKE) -C manager6 $@
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
set -e && for i in ${SUBDIRS}; do ${MAKE} -C $$i $@; done
|
||||
set -e && for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
||||
|
@ -4,8 +4,8 @@ all:
|
||||
|
||||
.PHONY: install
|
||||
install: ext6-pve.css
|
||||
install -d ${WWWCSSDIR}
|
||||
install -m 0644 $? ${WWWCSSDIR}
|
||||
install -d $(WWWCSSDIR)
|
||||
install -m 0644 $? $(WWWCSSDIR)
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
@ -4,8 +4,8 @@ all:
|
||||
|
||||
.PHONY: install
|
||||
install: README fontawesome-webfont.ttf FontAwesome.otf fontawesome-webfont.woff2 fontawesome-webfont.svg fontawesome-webfont.woff fontawesome-webfont.eot
|
||||
install -d ${WWWFONTSDIR}
|
||||
install -m 0644 $? ${WWWFONTSDIR}
|
||||
install -d $(WWWFONTSDIR)
|
||||
install -m 0644 $? $(WWWFONTSDIR)
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
@ -46,7 +46,7 @@ GNOME_IMAGES = \
|
||||
computer-template.png \
|
||||
computer.png
|
||||
|
||||
IMAGES = ${GNOME_IMAGES} \
|
||||
IMAGES = $(GNOME_IMAGES) \
|
||||
virt-viewer.png \
|
||||
tigervnc.png \
|
||||
novnc.png \
|
||||
@ -89,9 +89,9 @@ icon-sdn.svg: icon-sdn.dot
|
||||
fdp -Tsvg $< > $@
|
||||
|
||||
.PHONY: install
|
||||
install: ${IMAGES}
|
||||
install -d ${WWWIMAGEDIR}
|
||||
install -m 0644 ${IMAGES} ${WWWIMAGEDIR}
|
||||
install: $(IMAGES)
|
||||
install -d $(WWWIMAGEDIR)
|
||||
install -m 0644 $(IMAGES) $(WWWIMAGEDIR)
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
@ -34,7 +34,7 @@ Ext.define('PVE.Utils', {
|
||||
},
|
||||
|
||||
noSubKeyHtml: 'You do not have a valid subscription for this server. Please visit '
|
||||
+'<a target="_blank" href="https://www.proxmox.com/products/proxmox-ve/subscription-service-plans">'
|
||||
+'<a target="_blank" href="https://www.proxmox.com/en/proxmox-virtual-environment/pricing">'
|
||||
+'www.proxmox.com</a> to get a list of available options.',
|
||||
|
||||
kvm_ostypes: {
|
||||
@ -1726,7 +1726,7 @@ Ext.define('PVE.Utils', {
|
||||
rstore,
|
||||
/not (installed|initialized)/i,
|
||||
(_, error) => {
|
||||
nodename = nodename || 'localhost';
|
||||
nodename = nodename || Proxmox.NodeName;
|
||||
let maskTarget = maskOwnerCt ? view.ownerCt : view;
|
||||
rstore.stopUpdate();
|
||||
PVE.Utils.showCephInstallOrMask(maskTarget, error.statusText, nodename, win => {
|
||||
|
@ -156,12 +156,12 @@ Ext.define('PVE.NodeCephFSPanel', {
|
||||
dataIndex: 'name',
|
||||
},
|
||||
{
|
||||
header: 'Data Pool',
|
||||
header: gettext('Data Pool'),
|
||||
flex: 1,
|
||||
dataIndex: 'data_pool',
|
||||
},
|
||||
{
|
||||
header: 'Metadata Pool',
|
||||
header: gettext('Metadata Pool'),
|
||||
flex: 1,
|
||||
dataIndex: 'metadata_pool',
|
||||
},
|
||||
|
@ -73,7 +73,7 @@ Ext.define('PVE.CephCreateOsd', {
|
||||
value: '',
|
||||
autoSelect: false,
|
||||
allowBlank: true,
|
||||
emptyText: 'use OSD disk',
|
||||
emptyText: gettext('use OSD disk'),
|
||||
listeners: {
|
||||
change: function(field, val) {
|
||||
me.down('field[name=db_dev_size]').setDisabled(!val);
|
||||
@ -112,7 +112,7 @@ Ext.define('PVE.CephCreateOsd', {
|
||||
autoSelect: false,
|
||||
allowBlank: true,
|
||||
editable: true,
|
||||
emptyText: 'auto detect',
|
||||
emptyText: gettext('auto detect'),
|
||||
deleteEmpty: !me.isCreate,
|
||||
},
|
||||
],
|
||||
@ -127,7 +127,7 @@ Ext.define('PVE.CephCreateOsd', {
|
||||
value: '',
|
||||
autoSelect: false,
|
||||
allowBlank: true,
|
||||
emptyText: 'use OSD/DB disk',
|
||||
emptyText: gettext('use OSD/DB disk'),
|
||||
listeners: {
|
||||
change: function(field, val) {
|
||||
me.down('field[name=wal_dev_size]').setDisabled(!val);
|
||||
|
@ -196,7 +196,7 @@ Ext.define('PVE.CephOsdDetails', {
|
||||
},
|
||||
{
|
||||
xtype: 'panel',
|
||||
title: 'Devices',
|
||||
title: gettext('Devices'),
|
||||
tooltip: gettext('Physical devices used by the OSD'),
|
||||
items: [
|
||||
{
|
||||
|
@ -96,6 +96,12 @@ Ext.define('PVE.dc.BackupEdit', {
|
||||
|
||||
selectPoolMembers: function() {
|
||||
let me = this;
|
||||
let mode = me.lookup('modeSelector').getValue();
|
||||
|
||||
if (mode !== 'pool') {
|
||||
return;
|
||||
}
|
||||
|
||||
let vmgrid = me.lookup('vmgrid');
|
||||
let poolid = me.lookup('poolSelector').getValue();
|
||||
|
||||
|
@ -4,7 +4,7 @@ Ext.define('PVE.form.VlanField', {
|
||||
|
||||
deleteEmpty: false,
|
||||
|
||||
emptyText: 'no VLAN',
|
||||
emptyText: gettext('no VLAN'),
|
||||
|
||||
fieldLabel: gettext('VLAN Tag'),
|
||||
|
||||
|
@ -162,7 +162,7 @@ Ext.define('PVE.form.VMSelector', {
|
||||
setValue: function(value) {
|
||||
let me = this;
|
||||
if (!Ext.isArray(value)) {
|
||||
value = value.split(',');
|
||||
value = value.split(',').filter(v => v !== '');
|
||||
}
|
||||
|
||||
let store = me.getStore();
|
||||
|
@ -18,11 +18,11 @@ Ext.define('PVE.ha.FencingView', {
|
||||
viewConfig: {
|
||||
trackOver: false,
|
||||
deferEmptyText: false,
|
||||
emptyText: 'Use watchdog based fencing.',
|
||||
emptyText: gettext('Use watchdog based fencing.'),
|
||||
},
|
||||
columns: [
|
||||
{
|
||||
header: 'Node',
|
||||
header: gettext('Node'),
|
||||
width: 100,
|
||||
sortable: true,
|
||||
dataIndex: 'node',
|
||||
|
@ -69,7 +69,7 @@ Ext.define('PVE.ha.GroupInputPanel', {
|
||||
dataIndex: 'cpu',
|
||||
},
|
||||
{
|
||||
header: 'Priority',
|
||||
header: gettext('Priority'),
|
||||
xtype: 'widgetcolumn',
|
||||
dataIndex: 'priority',
|
||||
sortable: true,
|
||||
|
@ -191,6 +191,7 @@ Ext.define('PVE.window.Clone', {
|
||||
{
|
||||
xtype: 'textfield',
|
||||
name: 'name',
|
||||
vtype: 'DnsName',
|
||||
allowBlank: true,
|
||||
fieldLabel: me.guestType === 'lxc' ? gettext('Hostname') : gettext('Name'),
|
||||
},
|
||||
|
@ -315,6 +315,7 @@ Ext.define('PVE.window.Restore', {
|
||||
xtype: 'textfield',
|
||||
fieldLabel: me.vmtype === 'lxc' ? gettext('Hostname') : gettext('Name'),
|
||||
name: 'name',
|
||||
vtype: 'DnsName',
|
||||
reference: 'nameField',
|
||||
allowBlank: true,
|
||||
}, {
|
||||
|
@ -1,85 +1,85 @@
|
||||
/**
|
||||
* Utility class for setting/reading values from browser cookies.
|
||||
* Values can be written using the {@link #set} method.
|
||||
* Values can be read using the {@link #get} method.
|
||||
* A cookie can be invalidated on the client machine using the {@link #clear} method.
|
||||
*/
|
||||
Ext.define('Ext.util.Cookies', {
|
||||
singleton: true,
|
||||
|
||||
/**
|
||||
* Creates a cookie with the specified name and value. Additional settings for the cookie may be optionally specified
|
||||
* (for example: expiration, access restriction, SSL).
|
||||
* @param {String} name The name of the cookie to set.
|
||||
* @param {Object} value The value to set for the cookie.
|
||||
* @param {Object} [expires] Specify an expiration date the cookie is to persist until. Note that the specified Date
|
||||
* object will be converted to Greenwich Mean Time (GMT).
|
||||
* @param {String} [path] Setting a path on the cookie restricts access to pages that match that path. Defaults to all
|
||||
* pages ('/').
|
||||
* @param {String} [domain] Setting a domain restricts access to pages on a given domain (typically used to allow
|
||||
* cookie access across subdomains). For example, "sencha.com" will create a cookie that can be accessed from any
|
||||
* subdomain of sencha.com, including www.sencha.com, support.sencha.com, etc.
|
||||
* @param {Boolean} [secure] Specify true to indicate that the cookie should only be accessible via SSL on a page
|
||||
* using the HTTPS protocol. Defaults to false. Note that this will only work if the page calling this code uses the
|
||||
* HTTPS protocol, otherwise the cookie will be created with default options.
|
||||
*/
|
||||
set : function(name, value){
|
||||
var argv = arguments,
|
||||
argc = arguments.length,
|
||||
expires = (argc > 2) ? argv[2] : null,
|
||||
path = (argc > 3) ? argv[3] : '/',
|
||||
domain = (argc > 4) ? argv[4] : null,
|
||||
secure = (argc > 5) ? argv[5] : false;
|
||||
|
||||
document.cookie = name + "=" +
|
||||
escape(value) +
|
||||
((expires === null) ? "" : ("; expires=" + expires.toUTCString())) +
|
||||
((path === null) ? "" : ("; path=" + path)) +
|
||||
((domain === null) ? "" : ("; domain=" + domain)) +
|
||||
((secure === true) ? "; secure" : "");
|
||||
},
|
||||
|
||||
/**
|
||||
* Retrieves cookies that are accessible by the current page. If a cookie does not exist, `get()` returns null. The
|
||||
* following example retrieves the cookie called "valid" and stores the String value in the variable validStatus.
|
||||
*
|
||||
* var validStatus = Ext.util.Cookies.get("valid");
|
||||
*
|
||||
* @param {String} name The name of the cookie to get
|
||||
* @return {Object} Returns the cookie value for the specified name;
|
||||
* null if the cookie name does not exist.
|
||||
*/
|
||||
get : function(name) {
|
||||
var parts = document.cookie.split('; '),
|
||||
len = parts.length,
|
||||
item, i, ret;
|
||||
|
||||
// In modern browsers, a cookie with an empty string will be stored:
|
||||
// MyName=
|
||||
// In older versions of IE, it will be stored as:
|
||||
// MyName
|
||||
// So here we iterate over all the parts in an attempt to match the key.
|
||||
for (i = 0; i < len; ++i) {
|
||||
item = parts[i].split('=');
|
||||
if (item[0] === name) {
|
||||
ret = item[1];
|
||||
return ret ? unescape(ret) : '';
|
||||
}
|
||||
}
|
||||
return null;
|
||||
},
|
||||
|
||||
/**
|
||||
* Removes a cookie with the provided name from the browser
|
||||
* if found by setting its expiration date to sometime in the past.
|
||||
* @param {String} name The name of the cookie to remove
|
||||
* @param {String} [path] The path for the cookie.
|
||||
* This must be included if you included a path while setting the cookie.
|
||||
*/
|
||||
clear : function(name, path){
|
||||
if (this.get(name)) {
|
||||
path = path || '/';
|
||||
document.cookie = name + '=' + '; expires=Thu, 01-Jan-1970 00:00:01 GMT; path=' + path;
|
||||
}
|
||||
}
|
||||
});
|
||||
/**
|
||||
* Utility class for setting/reading values from browser cookies.
|
||||
* Values can be written using the {@link #set} method.
|
||||
* Values can be read using the {@link #get} method.
|
||||
* A cookie can be invalidated on the client machine using the {@link #clear} method.
|
||||
*/
|
||||
Ext.define('Ext.util.Cookies', {
|
||||
singleton: true,
|
||||
|
||||
/**
|
||||
* Creates a cookie with the specified name and value. Additional settings for the cookie may be optionally specified
|
||||
* (for example: expiration, access restriction, SSL).
|
||||
* @param {String} name The name of the cookie to set.
|
||||
* @param {Object} value The value to set for the cookie.
|
||||
* @param {Object} [expires] Specify an expiration date the cookie is to persist until. Note that the specified Date
|
||||
* object will be converted to Greenwich Mean Time (GMT).
|
||||
* @param {String} [path] Setting a path on the cookie restricts access to pages that match that path. Defaults to all
|
||||
* pages ('/').
|
||||
* @param {String} [domain] Setting a domain restricts access to pages on a given domain (typically used to allow
|
||||
* cookie access across subdomains). For example, "sencha.com" will create a cookie that can be accessed from any
|
||||
* subdomain of sencha.com, including www.sencha.com, support.sencha.com, etc.
|
||||
* @param {Boolean} [secure] Specify true to indicate that the cookie should only be accessible via SSL on a page
|
||||
* using the HTTPS protocol. Defaults to false. Note that this will only work if the page calling this code uses the
|
||||
* HTTPS protocol, otherwise the cookie will be created with default options.
|
||||
*/
|
||||
set: function(name, value) {
|
||||
var argv = arguments,
|
||||
argc = arguments.length,
|
||||
expires = argc > 2 ? argv[2] : null,
|
||||
path = argc > 3 ? argv[3] : '/',
|
||||
domain = argc > 4 ? argv[4] : null,
|
||||
secure = argc > 5 ? argv[5] : false;
|
||||
|
||||
document.cookie = name + "=" +
|
||||
escape(value) +
|
||||
(expires === null ? "" : "; expires=" + expires.toUTCString()) +
|
||||
(path === null ? "" : "; path=" + path) +
|
||||
(domain === null ? "" : "; domain=" + domain) +
|
||||
(secure === true ? "; secure" : "");
|
||||
},
|
||||
|
||||
/**
|
||||
* Retrieves cookies that are accessible by the current page. If a cookie does not exist, `get()` returns null. The
|
||||
* following example retrieves the cookie called "valid" and stores the String value in the variable validStatus.
|
||||
*
|
||||
* var validStatus = Ext.util.Cookies.get("valid");
|
||||
*
|
||||
* @param {String} name The name of the cookie to get
|
||||
* @return {Object} Returns the cookie value for the specified name;
|
||||
* null if the cookie name does not exist.
|
||||
*/
|
||||
get: function(name) {
|
||||
var parts = document.cookie.split('; '),
|
||||
len = parts.length,
|
||||
item, i, ret;
|
||||
|
||||
// In modern browsers, a cookie with an empty string will be stored:
|
||||
// MyName=
|
||||
// In older versions of IE, it will be stored as:
|
||||
// MyName
|
||||
// So here we iterate over all the parts in an attempt to match the key.
|
||||
for (i = 0; i < len; ++i) {
|
||||
item = parts[i].split('=');
|
||||
if (item[0] === name) {
|
||||
ret = item[1];
|
||||
return ret ? unescape(ret) : '';
|
||||
}
|
||||
}
|
||||
return null;
|
||||
},
|
||||
|
||||
/**
|
||||
* Removes a cookie with the provided name from the browser
|
||||
* if found by setting its expiration date to sometime in the past.
|
||||
* @param {String} name The name of the cookie to remove
|
||||
* @param {String} [path] The path for the cookie.
|
||||
* This must be included if you included a path while setting the cookie.
|
||||
*/
|
||||
clear: function(name, path) {
|
||||
if (this.get(name)) {
|
||||
path = path || '/';
|
||||
document.cookie = name + '=; expires=Thu, 01-Jan-1970 00:00:01 GMT; path=' + path;
|
||||
}
|
||||
},
|
||||
});
|
||||
|
@ -15,7 +15,7 @@ Ext.define('PVE.ClusterInfo', {
|
||||
'</tpl>',
|
||||
'<tr><td>Version:</td><td>{version}</td></tr>',
|
||||
'</table>',
|
||||
]
|
||||
],
|
||||
},
|
||||
});
|
||||
|
||||
@ -28,7 +28,7 @@ Ext.define('PVE.Datacenter', {
|
||||
if (loc === '') {
|
||||
return [''];
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
config: {
|
||||
@ -37,16 +37,16 @@ Ext.define('PVE.Datacenter', {
|
||||
{
|
||||
xtype: 'pveTitleBar',
|
||||
title: gettext('Datacenter'),
|
||||
pveBackButton: false
|
||||
pveBackButton: false,
|
||||
},
|
||||
{
|
||||
xtype: 'pveClusterInfo'
|
||||
xtype: 'pveClusterInfo',
|
||||
},
|
||||
{
|
||||
xtype: 'component',
|
||||
cls: 'dark',
|
||||
padding: 5,
|
||||
html: gettext('Nodes')
|
||||
html: gettext('Nodes'),
|
||||
},
|
||||
{
|
||||
xtype: 'list',
|
||||
@ -56,13 +56,13 @@ Ext.define('PVE.Datacenter', {
|
||||
listeners: {
|
||||
itemsingletap: function(list, index, target, record) {
|
||||
PVE.Workspace.gotoPage('nodes/' + record.get('name'));
|
||||
}
|
||||
},
|
||||
},
|
||||
itemTpl: '{name}' +
|
||||
'<br><small>Online: {[Proxmox.Utils.format_boolean(values.online)]}</small>' +
|
||||
'<br><small>Support: {[PVE.Utils.render_support_level(values.level)]}</small>'
|
||||
}
|
||||
]
|
||||
'<br><small>Support: {[PVE.Utils.render_support_level(values.level)]}</small>',
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
reload: function() {
|
||||
@ -81,7 +81,7 @@ Ext.define('PVE.Datacenter', {
|
||||
var d = response.result.data;
|
||||
me.summary.version = d.version;
|
||||
ci.setData(me.summary);
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
var list = me.down('list');
|
||||
@ -91,7 +91,7 @@ Ext.define('PVE.Datacenter', {
|
||||
method: 'GET',
|
||||
success: function(response) {
|
||||
var d = response.result.data;
|
||||
list.setData(d.filter(function(el) { return (el.type === "node"); }));
|
||||
list.setData(d.filter(function(el) { return el.type === "node"; }));
|
||||
|
||||
d.forEach(function(el) {
|
||||
if (el.type === "node") {
|
||||
@ -108,8 +108,8 @@ Ext.define('PVE.Datacenter', {
|
||||
ci.setData(me.summary);
|
||||
},
|
||||
failure: function(response) {
|
||||
me.setMasked({ xtype: 'loadmask', message: response.htmlStatus} );
|
||||
}
|
||||
me.setMasked({ xtype: 'loadmask', message: response.htmlStatus });
|
||||
},
|
||||
});
|
||||
},
|
||||
|
||||
@ -121,12 +121,12 @@ Ext.define('PVE.Datacenter', {
|
||||
text: gettext('Tasks'),
|
||||
handler: function() {
|
||||
PVE.Workspace.gotoPage('tasks');
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
]);
|
||||
|
||||
me.reload();
|
||||
}
|
||||
},
|
||||
|
||||
});
|
||||
|
||||
|
@ -4,15 +4,15 @@ Ext.define('PVE.LXCSummary', {
|
||||
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
return loc.match(/^nodes\/([^\s\/]+)\/lxc\/(\d+)$/);
|
||||
}
|
||||
return loc.match(/^nodes\/([^\s/]+)\/lxc\/(\d+)$/);
|
||||
},
|
||||
},
|
||||
|
||||
vmtype: 'lxc',
|
||||
|
||||
config_keys: [
|
||||
'hostname','ostype', , 'memory', 'swap', 'cpulimit', 'cpuunits',
|
||||
/^net\d+/, 'rootfs', /^mp\d+/, 'nameserver', 'searchdomain','description'
|
||||
'hostname', 'ostype', 'memory', 'swap', 'cpulimit', 'cpuunits',
|
||||
/^net\d+/, 'rootfs', /^mp\d+/, 'nameserver', 'searchdomain', 'description',
|
||||
],
|
||||
|
||||
initialize: function() {
|
||||
@ -29,5 +29,5 @@ Ext.define('PVE.LXCSummary', {
|
||||
me.down('titlebar').setTitle('CT: ' + me.vmid);
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
@ -18,7 +18,6 @@ Ext.define('PVE.Login', {
|
||||
});
|
||||
errlabel.show();
|
||||
} else {
|
||||
|
||||
Ext.Msg.show({
|
||||
title: 'Two-Factor Authentication',
|
||||
message: 'Please enter your OTP verification code:',
|
||||
@ -33,7 +32,7 @@ Ext.define('PVE.Login', {
|
||||
} else {
|
||||
me.mask({
|
||||
xtype: 'loadmask',
|
||||
message: 'Loading...'
|
||||
message: 'Loading...',
|
||||
});
|
||||
Proxmox.Utils.API2Request({
|
||||
url: '/api2/extjs/access/tfa',
|
||||
@ -53,13 +52,12 @@ Ext.define('PVE.Login', {
|
||||
me.unmask();
|
||||
Proxmox.Utils.authClear();
|
||||
errlabel.show();
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
config: {
|
||||
@ -71,7 +69,7 @@ Ext.define('PVE.Login', {
|
||||
xtype: 'image',
|
||||
src: '/pve2/images/proxmox_logo.png',
|
||||
height: 30,
|
||||
width: 209
|
||||
width: 209,
|
||||
},
|
||||
{
|
||||
xtype: 'fieldset',
|
||||
@ -82,21 +80,21 @@ Ext.define('PVE.Login', {
|
||||
placeHolder: gettext('User name'),
|
||||
itemId: 'userNameTextField',
|
||||
name: 'username',
|
||||
required: true
|
||||
required: true,
|
||||
},
|
||||
{
|
||||
xtype: 'passwordfield',
|
||||
placeHolder: gettext('Password'),
|
||||
itemId: 'passwordTextField',
|
||||
name: 'password',
|
||||
required: true
|
||||
required: true,
|
||||
},
|
||||
{
|
||||
xtype: 'pveRealmSelector',
|
||||
itemId: 'realmSelectorField',
|
||||
name: 'realm',
|
||||
}
|
||||
]
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
xtype: 'label',
|
||||
@ -105,7 +103,7 @@ Ext.define('PVE.Login', {
|
||||
hidden: true,
|
||||
hideAnimation: 'fadeOut',
|
||||
showAnimation: 'fadeIn',
|
||||
style: 'color:#990000;margin:5px 0px;'
|
||||
style: 'color:#990000;margin:5px 0px;',
|
||||
},
|
||||
{
|
||||
xtype: 'button',
|
||||
@ -143,12 +141,12 @@ Ext.define('PVE.Login', {
|
||||
} else {
|
||||
PVE.Workspace.updateLoginData(data);
|
||||
}
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('PVE.field.TFACode', {
|
||||
@ -157,7 +155,7 @@ Ext.define('PVE.field.TFACode', {
|
||||
|
||||
config: {
|
||||
component: {
|
||||
type: 'number'
|
||||
type: 'number',
|
||||
},
|
||||
maxLength: 6,
|
||||
required: true,
|
||||
|
@ -4,6 +4,7 @@ include ../../defines.mk
|
||||
# extjs/classic/classic/src/util/Cookies.js
|
||||
|
||||
JSSRC= \
|
||||
WidgetToolkitUtils.js \
|
||||
Cookies.js \
|
||||
../manager6/Utils.js \
|
||||
../manager6/Parser.js \
|
||||
@ -27,14 +28,16 @@ JSSRC= \
|
||||
|
||||
all:
|
||||
|
||||
pvemanager-mobile.js: ${JSSRC}
|
||||
cat ${JSSRC} >$@.tmp
|
||||
pvemanager-mobile.js: $(JSSRC)
|
||||
cat $(JSSRC) >$@.tmp
|
||||
mv $@.tmp $@
|
||||
|
||||
.PHONY: install
|
||||
install: pvemanager-mobile.js
|
||||
install -d ${WWWTOUCHDIR}
|
||||
install -m 0644 pvemanager-mobile.js ${WWWTOUCHDIR}
|
||||
install: pvemanager-mobile.js index.html.tpl pve.css
|
||||
install -d $(WWWTOUCHDIR)
|
||||
install -m 0644 index.html.tpl $(WWWTOUCHDIR)
|
||||
install -m 0644 pve.css $(WWWTOUCHDIR)
|
||||
install -m 0644 pvemanager-mobile.js $(WWWTOUCHDIR)
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
@ -9,8 +9,8 @@ Ext.define('PVE.MenuButton', {
|
||||
|
||||
var data = me.getMenuItems() || [];
|
||||
|
||||
var addHide = function (fn) {
|
||||
return function () {
|
||||
var addHide = function(fn) {
|
||||
return function() {
|
||||
if (me.menuPanel) {
|
||||
me.menuPanel.hide();
|
||||
Ext.Viewport.remove(me.menuPanel);
|
||||
@ -30,7 +30,7 @@ Ext.define('PVE.MenuButton', {
|
||||
text: gettext('Datacenter'),
|
||||
handler: addHide(function() {
|
||||
PVE.Workspace.gotoPage('');
|
||||
})
|
||||
}),
|
||||
});
|
||||
}
|
||||
|
||||
@ -38,18 +38,18 @@ Ext.define('PVE.MenuButton', {
|
||||
items.push(Ext.apply(el, {
|
||||
xtype: 'button',
|
||||
ui: 'plain',
|
||||
handler: addHide(el.handler)
|
||||
handler: addHide(el.handler),
|
||||
}));
|
||||
});
|
||||
|
||||
if (me.getPveStdMenu()) {
|
||||
items.push({
|
||||
items.push({
|
||||
xtype: 'button',
|
||||
ui: 'plain',
|
||||
text: gettext('Logout'),
|
||||
handler: addHide(function() {
|
||||
PVE.Workspace.showLogin();
|
||||
})
|
||||
}),
|
||||
});
|
||||
}
|
||||
|
||||
@ -59,10 +59,10 @@ Ext.define('PVE.MenuButton', {
|
||||
visible: false,
|
||||
minWidth: 200,
|
||||
layout: {
|
||||
type:'vbox',
|
||||
align: 'stretch'
|
||||
type: 'vbox',
|
||||
align: 'stretch',
|
||||
},
|
||||
items: items
|
||||
items: items,
|
||||
});
|
||||
|
||||
PVE.Workspace.history.on('change', function() {
|
||||
@ -77,14 +77,14 @@ Ext.define('PVE.MenuButton', {
|
||||
config: {
|
||||
menuItems: undefined,
|
||||
pveStdMenu: false, // add LOGOUT
|
||||
handler: function() {
|
||||
handler: function() {
|
||||
var me = this;
|
||||
|
||||
if (!me.menuPanel) {
|
||||
me.createMenuPanel();
|
||||
}
|
||||
me.menuPanel.showBy(me, 'tr-bc?');
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
initialize: function() {
|
||||
@ -95,6 +95,5 @@ Ext.define('PVE.MenuButton', {
|
||||
if (me.getPveStdMenu()) {
|
||||
me.setIconCls('more');
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
});
|
||||
|
@ -9,9 +9,9 @@ Ext.define('PVE.MigrateBase', {
|
||||
items: [
|
||||
{
|
||||
xtype: 'pveTitleBar',
|
||||
pveReloadButton: false
|
||||
pveReloadButton: false,
|
||||
},
|
||||
{
|
||||
{
|
||||
xtype: 'formpanel',
|
||||
flex: 1,
|
||||
padding: 10,
|
||||
@ -27,21 +27,21 @@ Ext.define('PVE.MigrateBase', {
|
||||
},
|
||||
{
|
||||
xtype: 'checkboxfield',
|
||||
name : 'online',
|
||||
name: 'online',
|
||||
checked: true,
|
||||
label: gettext('Online')
|
||||
}
|
||||
]
|
||||
label: gettext('Online'),
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
xtype: 'button',
|
||||
itemId: 'migrate',
|
||||
ui: 'action',
|
||||
text: gettext('Migrate')
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
text: gettext('Migrate'),
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
initialize: function() {
|
||||
@ -52,7 +52,7 @@ Ext.define('PVE.MigrateBase', {
|
||||
btn.setHandler(function() {
|
||||
var form = this.up('formpanel');
|
||||
var values = form.getValues();
|
||||
|
||||
|
||||
if (!values.target) {
|
||||
Ext.Msg.alert('Error', 'Please select a target node');
|
||||
return;
|
||||
@ -67,12 +67,12 @@ Ext.define('PVE.MigrateBase', {
|
||||
},
|
||||
success: function(response, options) {
|
||||
var upid = response.result.data;
|
||||
var page = 'nodes/' + me.nodename + '/tasks/' + upid;
|
||||
var page = 'nodes/' + me.nodename + '/tasks/' + upid;
|
||||
PVE.Workspace.gotoPage(page);
|
||||
}
|
||||
},
|
||||
});
|
||||
});
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('PVE.QemuMigrate', {
|
||||
@ -82,8 +82,8 @@ Ext.define('PVE.QemuMigrate', {
|
||||
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
return loc.match(/^nodes\/([^\s\/]+)\/qemu\/(\d+)\/migrate$/);
|
||||
}
|
||||
return loc.match(/^nodes\/([^\s/]+)\/qemu\/(\d+)\/migrate$/);
|
||||
},
|
||||
},
|
||||
|
||||
initialize: function() {
|
||||
@ -100,7 +100,7 @@ Ext.define('PVE.QemuMigrate', {
|
||||
me.down('titlebar').setTitle(gettext('Migrate') + ': VM ' + me.vmid);
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('PVE.LXCMigrate', {
|
||||
@ -110,8 +110,8 @@ Ext.define('PVE.LXCMigrate', {
|
||||
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
return loc.match(/^nodes\/([^\s\/]+)\/lxc\/(\d+)\/migrate$/);
|
||||
}
|
||||
return loc.match(/^nodes\/([^\s/]+)\/lxc\/(\d+)\/migrate$/);
|
||||
},
|
||||
},
|
||||
|
||||
initialize: function() {
|
||||
@ -128,5 +128,5 @@ Ext.define('PVE.LXCMigrate', {
|
||||
me.down('titlebar').setTitle(gettext('Migrate') + ': CT ' + me.vmid);
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
@ -7,19 +7,19 @@ Ext.define('PVE.form.NodeSelector', {
|
||||
valueField: 'node',
|
||||
displayField: 'node',
|
||||
store: {
|
||||
fields: [ 'node', 'cpu', 'maxcpu', 'mem', 'maxmem', 'uptime' ],
|
||||
fields: ['node', 'cpu', 'maxcpu', 'mem', 'maxmem', 'uptime'],
|
||||
autoLoad: true,
|
||||
proxy: {
|
||||
type: 'pve',
|
||||
url: '/api2/json/nodes'
|
||||
url: '/api2/json/nodes',
|
||||
},
|
||||
sorters: [
|
||||
{
|
||||
property : 'node',
|
||||
direction: 'ASC'
|
||||
}
|
||||
]
|
||||
property: 'node',
|
||||
direction: 'ASC',
|
||||
},
|
||||
],
|
||||
},
|
||||
value: ''
|
||||
}
|
||||
value: '',
|
||||
},
|
||||
});
|
||||
|
@ -27,9 +27,9 @@ Ext.define('PVE.NodeInfo', {
|
||||
}
|
||||
var per = values.cpu * 100;
|
||||
return per.toFixed(2) + "% (" + values.cpuinfo.cpus + " CPUs)";
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
});
|
||||
|
||||
@ -39,25 +39,25 @@ Ext.define('PVE.NodeSummary', {
|
||||
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
return loc.match(/^nodes\/([^\s\/]+)$/);
|
||||
}
|
||||
return loc.match(/^nodes\/([^\s/]+)$/);
|
||||
},
|
||||
},
|
||||
|
||||
nodename: undefined,
|
||||
|
||||
config: {
|
||||
items: [
|
||||
{
|
||||
xtype: 'pveTitleBar'
|
||||
{
|
||||
xtype: 'pveTitleBar',
|
||||
},
|
||||
{
|
||||
xtype: 'pveNodeInfo'
|
||||
xtype: 'pveNodeInfo',
|
||||
},
|
||||
{
|
||||
xtype: 'component',
|
||||
cls: 'dark',
|
||||
padding: 5,
|
||||
html: gettext('Virtual machines')
|
||||
html: gettext('Virtual machines'),
|
||||
},
|
||||
{
|
||||
xtype: 'list',
|
||||
@ -65,9 +65,9 @@ Ext.define('PVE.NodeSummary', {
|
||||
disableSelection: true,
|
||||
listeners: {
|
||||
itemsingletap: function(list, index, target, record) {
|
||||
PVE.Workspace.gotoPage('nodes/' + record.get('nodename') + '/' +
|
||||
PVE.Workspace.gotoPage('nodes/' + record.get('nodename') + '/' +
|
||||
record.get('type') + '/' + record.get('vmid'));
|
||||
}
|
||||
},
|
||||
},
|
||||
grouped: true,
|
||||
itemTpl: [
|
||||
@ -91,15 +91,15 @@ Ext.define('PVE.NodeSummary', {
|
||||
return '-';
|
||||
}
|
||||
return (values.cpu*100).toFixed(1) + '%';
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
reload: function() {
|
||||
var me = this;
|
||||
var me = this;
|
||||
|
||||
var ni = me.down('pveNodeInfo');
|
||||
|
||||
@ -109,10 +109,10 @@ Ext.define('PVE.NodeSummary', {
|
||||
success: function(response) {
|
||||
var d = response.result.data;
|
||||
if (d.pveversion) {
|
||||
d.pveversion = d.pveversion.replace(/pve\-manager\//, '');
|
||||
d.pveversion = d.pveversion.replace(/pve-manager\//, '');
|
||||
}
|
||||
ni.setData(d);
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
@ -121,7 +121,7 @@ Ext.define('PVE.NodeSummary', {
|
||||
list.setMasked(false);
|
||||
|
||||
var error_handler = function(response) {
|
||||
list.setMasked({ xtype: 'loadmask', message: response.htmlStatus} );
|
||||
list.setMasked({ xtype: 'loadmask', message: response.htmlStatus });
|
||||
};
|
||||
|
||||
Proxmox.Utils.API2Request({
|
||||
@ -130,7 +130,7 @@ Ext.define('PVE.NodeSummary', {
|
||||
success: function(response) {
|
||||
var d = response.result.data;
|
||||
d.nodename = me.nodename;
|
||||
d.forEach(function(el) { el.type = 'lxc'; el.nodename = me.nodename });
|
||||
d.forEach(function(el) { el.type = 'lxc'; el.nodename = me.nodename; });
|
||||
me.store.each(function(rec) {
|
||||
if (rec.get('type') === 'lxc') {
|
||||
rec.destroy();
|
||||
@ -138,7 +138,7 @@ Ext.define('PVE.NodeSummary', {
|
||||
});
|
||||
me.store.add(d);
|
||||
},
|
||||
failure: error_handler
|
||||
failure: error_handler,
|
||||
});
|
||||
|
||||
Proxmox.Utils.API2Request({
|
||||
@ -146,7 +146,7 @@ Ext.define('PVE.NodeSummary', {
|
||||
method: 'GET',
|
||||
success: function(response) {
|
||||
var d = response.result.data;
|
||||
d.forEach(function(el) { el.type = 'qemu'; el.nodename = me.nodename });
|
||||
d.forEach(function(el) { el.type = 'qemu'; el.nodename = me.nodename; });
|
||||
me.store.each(function(rec) {
|
||||
if (rec.get('type') === 'qemu') {
|
||||
rec.destroy();
|
||||
@ -154,9 +154,8 @@ Ext.define('PVE.NodeSummary', {
|
||||
});
|
||||
me.store.add(d);
|
||||
},
|
||||
failure: error_handler
|
||||
failure: error_handler,
|
||||
});
|
||||
|
||||
},
|
||||
|
||||
initialize: function() {
|
||||
@ -176,17 +175,17 @@ Ext.define('PVE.NodeSummary', {
|
||||
text: gettext('Tasks'),
|
||||
handler: function() {
|
||||
PVE.Workspace.gotoPage('nodes/' + me.nodename + '/tasks');
|
||||
}
|
||||
},
|
||||
},
|
||||
]);
|
||||
|
||||
me.store = Ext.create('Ext.data.Store', {
|
||||
fields: [ 'name', 'vmid', 'nodename', 'type', 'memory', 'uptime', 'mem', 'maxmem', 'cpu', 'cpus'],
|
||||
fields: ['name', 'vmid', 'nodename', 'type', 'memory', 'uptime', 'mem', 'maxmem', 'cpu', 'cpus'],
|
||||
sorters: ['vmid'],
|
||||
grouper: {
|
||||
groupFn: function(record) {
|
||||
return record.get('type');
|
||||
}
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
@ -196,5 +195,5 @@ Ext.define('PVE.NodeSummary', {
|
||||
me.reload();
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
@ -6,7 +6,7 @@ Ext.define('PVE.ATitleBar', {
|
||||
docked: 'top',
|
||||
pveReloadButton: true,
|
||||
pveBackButton: true,
|
||||
pveStdMenu: true // add 'Login' and 'Datacenter' to menu by default
|
||||
pveStdMenu: true, // add 'Login' and 'Datacenter' to menu by default
|
||||
},
|
||||
|
||||
initialize: function() {
|
||||
@ -22,7 +22,7 @@ Ext.define('PVE.ATitleBar', {
|
||||
iconCls: 'arrow_left',
|
||||
handler: function() {
|
||||
PVE.Workspace.goBack();
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
@ -32,18 +32,18 @@ Ext.define('PVE.ATitleBar', {
|
||||
iconCls: 'refresh',
|
||||
handler: function() {
|
||||
this.up('pvePage').reload();
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
items.push({
|
||||
xtype: 'pveMenuButton',
|
||||
align: 'right',
|
||||
pveStdMenu: me.getPveStdMenu()
|
||||
pveStdMenu: me.getPveStdMenu(),
|
||||
});
|
||||
|
||||
me.setItems(items);
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
});
|
||||
|
@ -1,6 +1,6 @@
|
||||
Ext.define('PVE.RestProxy', {
|
||||
extend: 'Ext.data.RestProxy',
|
||||
alias : 'proxy.pve',
|
||||
alias: 'proxy.pve',
|
||||
|
||||
constructor: function(config) {
|
||||
var me = this;
|
||||
@ -8,33 +8,32 @@ Ext.define('PVE.RestProxy', {
|
||||
config = config || {};
|
||||
|
||||
Ext.applyIf(config, {
|
||||
pageParam : null,
|
||||
pageParam: null,
|
||||
startParam: null,
|
||||
limitParam: null,
|
||||
groupParam: null,
|
||||
sortParam: null,
|
||||
filterParam: null,
|
||||
noCache : false,
|
||||
noCache: false,
|
||||
reader: {
|
||||
type: 'json',
|
||||
rootProperty: config.root || 'data'
|
||||
rootProperty: config.root || 'data',
|
||||
},
|
||||
afterRequest: function(request, success) {
|
||||
me.fireEvent('afterload', me, request, success);
|
||||
return;
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
me.callParent([config]);
|
||||
}
|
||||
me.callParent([config]);
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('pve-domains', {
|
||||
extend: "Ext.data.Model",
|
||||
|
||||
config: {
|
||||
fields: [ 'realm', 'type', 'comment', 'default', 'tfa',
|
||||
{
|
||||
fields: ['realm', 'type', 'comment', 'default', 'tfa',
|
||||
{
|
||||
name: 'descr',
|
||||
// Note: We use this in the RealmComboBox.js
|
||||
// (see Bug #125)
|
||||
@ -53,25 +52,25 @@ Ext.define('pve-domains', {
|
||||
}
|
||||
|
||||
return text;
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
],
|
||||
proxy: {
|
||||
type: 'pve',
|
||||
url: "/api2/json/access/domains"
|
||||
}
|
||||
}
|
||||
url: "/api2/json/access/domains",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('pve-tasks', {
|
||||
extend: 'Ext.data.Model',
|
||||
config: {
|
||||
fields: [
|
||||
{ name: 'starttime', type : 'date', dateFormat: 'timestamp' },
|
||||
{ name: 'endtime', type : 'date', dateFormat: 'timestamp' },
|
||||
fields: [
|
||||
{ name: 'starttime', type: 'date', dateFormat: 'timestamp' },
|
||||
{ name: 'endtime', type: 'date', dateFormat: 'timestamp' },
|
||||
{ name: 'pid', type: 'int' },
|
||||
'node', 'upid', 'user', 'status', 'type', 'id'
|
||||
'node', 'upid', 'user', 'status', 'type', 'id',
|
||||
],
|
||||
idProperty: 'upid'
|
||||
}
|
||||
idProperty: 'upid',
|
||||
},
|
||||
});
|
||||
|
@ -4,15 +4,15 @@ Ext.define('PVE.QemuSummary', {
|
||||
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
return loc.match(/^nodes\/([^\s\/]+)\/qemu\/(\d+)$/);
|
||||
}
|
||||
return loc.match(/^nodes\/([^\s/]+)\/qemu\/(\d+)$/);
|
||||
},
|
||||
},
|
||||
|
||||
vmtype: 'qemu',
|
||||
|
||||
config_keys: [
|
||||
'name', 'memory', 'sockets', 'cores', 'ostype', 'bootdisk', /^net\d+/,
|
||||
/^ide\d+/, /^virtio\d+/, /^sata\d+/, /^scsi\d+/, /^unused\d+/
|
||||
/^ide\d+/, /^virtio\d+/, /^sata\d+/, /^scsi\d+/, /^unused\d+/,
|
||||
],
|
||||
|
||||
initialize: function() {
|
||||
@ -29,5 +29,5 @@ Ext.define('PVE.QemuSummary', {
|
||||
me.down('titlebar').setTitle('VM: ' + me.vmid);
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
@ -7,7 +7,7 @@ Ext.define('PVE.form.RealmSelector', {
|
||||
valueField: 'realm',
|
||||
displayField: 'descr',
|
||||
store: { model: 'pve-domains' },
|
||||
value: 'pam'
|
||||
value: 'pam',
|
||||
},
|
||||
|
||||
needOTP: function(realm) {
|
||||
@ -24,7 +24,7 @@ Ext.define('PVE.form.RealmSelector', {
|
||||
var me = this;
|
||||
|
||||
me.callParent();
|
||||
|
||||
|
||||
var realmstore = me.getStore();
|
||||
|
||||
realmstore.load({
|
||||
@ -34,7 +34,7 @@ Ext.define('PVE.form.RealmSelector', {
|
||||
if (!def || !realmstore.findRecord('realm', def)) {
|
||||
def = 'pam';
|
||||
Ext.each(r, function(record) {
|
||||
if (record.get('default')) {
|
||||
if (record.get('default')) {
|
||||
def = record.get('realm');
|
||||
}
|
||||
});
|
||||
@ -43,7 +43,7 @@ Ext.define('PVE.form.RealmSelector', {
|
||||
me.setValue(def);
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
},
|
||||
});
|
||||
|
@ -5,7 +5,7 @@ Ext.define('PVE.TaskListBase', {
|
||||
baseUrl: undefined,
|
||||
items: [
|
||||
{
|
||||
xtype: 'pveTitleBar'
|
||||
xtype: 'pveTitleBar',
|
||||
},
|
||||
{
|
||||
xtype: 'list',
|
||||
@ -13,9 +13,9 @@ Ext.define('PVE.TaskListBase', {
|
||||
disableSelection: true,
|
||||
listeners: {
|
||||
itemsingletap: function(list, index, target, record) {
|
||||
PVE.Workspace.gotoPage('nodes/' + record.get('node') + '/tasks/' +
|
||||
PVE.Workspace.gotoPage('nodes/' + record.get('node') + '/tasks/' +
|
||||
record.get('upid'));
|
||||
}
|
||||
},
|
||||
},
|
||||
itemTpl: [
|
||||
'<div style="vertical-align: middle;">' +
|
||||
@ -30,11 +30,11 @@ Ext.define('PVE.TaskListBase', {
|
||||
},
|
||||
status: function(values) {
|
||||
return Ext.String.ellipsis(values.status, 160);
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
reload: function() {
|
||||
@ -50,23 +50,23 @@ Ext.define('PVE.TaskListBase', {
|
||||
model: 'pve-tasks',
|
||||
proxy: {
|
||||
type: 'pve',
|
||||
url: '/api2/json' + me.getBaseUrl()
|
||||
url: '/api2/json' + me.getBaseUrl(),
|
||||
},
|
||||
sorters: [
|
||||
{
|
||||
property : 'starttime',
|
||||
direction: 'DESC'
|
||||
}
|
||||
]
|
||||
property: 'starttime',
|
||||
direction: 'DESC',
|
||||
},
|
||||
],
|
||||
});
|
||||
|
||||
var list = me.down('list');
|
||||
list.setStore(me.store);
|
||||
|
||||
me.reload();
|
||||
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('PVE.ClusterTaskList', {
|
||||
@ -75,11 +75,11 @@ Ext.define('PVE.ClusterTaskList', {
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
return loc.match(/^tasks$/);
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
config: {
|
||||
baseUrl: '/cluster/tasks'
|
||||
baseUrl: '/cluster/tasks',
|
||||
},
|
||||
|
||||
initialize: function() {
|
||||
@ -93,7 +93,7 @@ Ext.define('PVE.ClusterTaskList', {
|
||||
}
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('PVE.NodeTaskList', {
|
||||
@ -101,8 +101,8 @@ Ext.define('PVE.NodeTaskList', {
|
||||
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
return loc.match(/^nodes\/([^\s\/]+)\/tasks$/);
|
||||
}
|
||||
return loc.match(/^nodes\/([^\s/]+)\/tasks$/);
|
||||
},
|
||||
},
|
||||
|
||||
nodename: undefined,
|
||||
@ -122,7 +122,7 @@ Ext.define('PVE.NodeTaskList', {
|
||||
me.down('titlebar').setTitle(gettext('Tasks') + ': ' + me.nodename);
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
|
@ -4,8 +4,8 @@ Ext.define('PVE.TaskViewer', {
|
||||
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
return loc.match(/^nodes\/([^\s\/]+)\/tasks\/([^\s\/]+)$/);
|
||||
}
|
||||
return loc.match(/^nodes\/([^\s/]+)\/tasks\/([^\s/]+)$/);
|
||||
},
|
||||
},
|
||||
|
||||
nodename: undefined,
|
||||
@ -15,8 +15,8 @@ Ext.define('PVE.TaskViewer', {
|
||||
|
||||
config: {
|
||||
items: [
|
||||
{
|
||||
xtype: 'pveTitleBar'
|
||||
{
|
||||
xtype: 'pveTitleBar',
|
||||
},
|
||||
{
|
||||
itemId: 'taskStatus',
|
||||
@ -29,14 +29,14 @@ Ext.define('PVE.TaskViewer', {
|
||||
'<tpl for=".">',
|
||||
'<tr><td>{key}</td><td>{value}</td></tr>',
|
||||
'</tpl>',
|
||||
'</table>'
|
||||
]
|
||||
},
|
||||
'</table>',
|
||||
],
|
||||
},
|
||||
{
|
||||
xtype: 'component',
|
||||
cls: 'dark',
|
||||
padding: 5,
|
||||
html: gettext('Log')
|
||||
padding: 5,
|
||||
html: gettext('Log'),
|
||||
},
|
||||
{
|
||||
itemId: 'taskLog',
|
||||
@ -46,9 +46,9 @@ Ext.define('PVE.TaskViewer', {
|
||||
styleHtmlContent: true,
|
||||
style: 'background-color:white;white-space: pre;font-family: Monospace;',
|
||||
data: {},
|
||||
tpl: '{text}'
|
||||
}
|
||||
]
|
||||
tpl: '{text}',
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
reloadLog: function() {
|
||||
@ -69,8 +69,8 @@ Ext.define('PVE.TaskViewer', {
|
||||
logCmp.setData({ text: text });
|
||||
},
|
||||
failure: function(response) {
|
||||
logCmp.setData({ text: response.htmlStatus } );
|
||||
}
|
||||
logCmp.setData({ text: response.htmlStatus });
|
||||
},
|
||||
});
|
||||
},
|
||||
|
||||
@ -78,7 +78,6 @@ Ext.define('PVE.TaskViewer', {
|
||||
var me = this;
|
||||
|
||||
var statusCmp = me.down('#taskStatus');
|
||||
var logCmp = me.down('#taskLog');
|
||||
|
||||
Proxmox.Utils.API2Request({
|
||||
url: "/nodes/" + me.nodename + "/tasks/" + me.upid + "/status",
|
||||
@ -101,8 +100,8 @@ Ext.define('PVE.TaskViewer', {
|
||||
}
|
||||
},
|
||||
failure: function(response) {
|
||||
me.setMasked({ xtype: 'loadmask', message: response.htmlStatus} );
|
||||
}
|
||||
me.setMasked({ xtype: 'loadmask', message: response.htmlStatus });
|
||||
},
|
||||
});
|
||||
},
|
||||
|
||||
@ -124,5 +123,5 @@ Ext.define('PVE.TaskViewer', {
|
||||
me.reload();
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
@ -1,8 +1,15 @@
|
||||
// Sencha Touch related things
|
||||
|
||||
Proxmox.Utils.toolkit = 'touch',
|
||||
Proxmox.Utils.toolkit = 'touch';
|
||||
|
||||
Ext.Ajax.setDisableCaching(false);
|
||||
|
||||
// do not send '_dc' parameter
|
||||
Ext.Ajax.disableCaching = false;
|
||||
|
||||
Ext.MessageBox = Ext.Msg = {
|
||||
alert: (title, message) => console.warn(title, message),
|
||||
show: ({ title, message }) => console.warn(title, message),
|
||||
};
|
||||
|
||||
Ext.Loader.injectScriptElement = (url) => console.warn(`surpressed loading ${url}`);
|
||||
|
@ -23,14 +23,14 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
},
|
||||
failure: function(response, opts) {
|
||||
Ext.Msg.alert('Error', response.htmlStatus);
|
||||
}
|
||||
},
|
||||
});
|
||||
},
|
||||
|
||||
config: {
|
||||
items: [
|
||||
{
|
||||
xtype: 'pveTitleBar'
|
||||
xtype: 'pveTitleBar',
|
||||
},
|
||||
{
|
||||
xtype: 'component',
|
||||
@ -61,17 +61,17 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
return per.toFixed(2) + "% (" + values.cpus + " CPUs)";
|
||||
},
|
||||
status: function(values) {
|
||||
return values.qmpstatus ? values.qmpstatus :
|
||||
values.status;
|
||||
}
|
||||
}
|
||||
]
|
||||
return values.qmpstatus ? values.qmpstatus
|
||||
: values.status;
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
xtype: 'component',
|
||||
cls: 'dark',
|
||||
padding: 5,
|
||||
html: gettext('Configuration')
|
||||
html: gettext('Configuration'),
|
||||
},
|
||||
{
|
||||
xtype: 'container',
|
||||
@ -85,10 +85,10 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
'<tpl for=".">',
|
||||
'<tr><td>{key}</td><td>{value}</td></tr>',
|
||||
'</tpl>',
|
||||
'</table>'
|
||||
]
|
||||
}
|
||||
]
|
||||
'</table>',
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
reload: function() {
|
||||
@ -111,7 +111,7 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
|
||||
vm_stat.setData(d);
|
||||
},
|
||||
failure: error_handler
|
||||
failure: error_handler,
|
||||
});
|
||||
|
||||
var vm_cfg = me.down('#vmconfig');
|
||||
@ -125,7 +125,7 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
var kv = PVE.Workspace.obj_to_kv(d, me.config_keys);
|
||||
vm_cfg.setData(kv);
|
||||
},
|
||||
failure: error_handler
|
||||
failure: error_handler,
|
||||
});
|
||||
},
|
||||
|
||||
@ -139,14 +139,14 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
text: gettext('Start'),
|
||||
handler: function() {
|
||||
me.vm_command("start", {});
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
text: gettext('Stop'),
|
||||
handler: function() {
|
||||
me.vm_command("stop", {});
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
var bottom_items = [{
|
||||
@ -154,27 +154,26 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
handler: function() {
|
||||
PVE.Workspace.gotoPage('nodes/' + me.nodename + '/' + me.vmtype +
|
||||
'/' + me.vmid +'/migrate');
|
||||
}
|
||||
},
|
||||
}];
|
||||
|
||||
// use qmpstatus with qemu, as it's exacter
|
||||
var vm_status = (me.vmtype === 'qemu') ? data.qmpstatus : data.status;
|
||||
|
||||
if(vm_status === 'running') {
|
||||
var vm_status = me.vmtype === 'qemu' ? data.qmpstatus : data.status;
|
||||
|
||||
if (vm_status === 'running') {
|
||||
top_items.push(
|
||||
{
|
||||
text: gettext('Shutdown'),
|
||||
handler: function() {
|
||||
me.vm_command("shutdown", {});
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
text: gettext('Suspend'),
|
||||
handler: function() {
|
||||
me.vm_command("suspend", {});
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
);
|
||||
|
||||
bottom_items.push({
|
||||
@ -183,32 +182,30 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
var vmtype = me.vmtype === 'qemu' ? 'kvm' : me.vmtype;
|
||||
PVE.Utils.openConsoleWindow('html5', vmtype, me.vmid,
|
||||
me.nodename);
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
if(data.spice || me.vmtype==='lxc') {
|
||||
if (data.spice || me.vmtype==='lxc') {
|
||||
bottom_items.push({
|
||||
text: gettext('Spice'),
|
||||
handler: function() {
|
||||
var vmtype = me.vmtype === 'qemu' ? 'kvm' : me.vmtype;
|
||||
PVE.Utils.openConsoleWindow('vv', vmtype, me.vmid,
|
||||
me.nodename);
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
} else if(vm_status === 'paused') {
|
||||
} else if (vm_status === 'paused') {
|
||||
top_items.push({
|
||||
text: gettext('Resume'),
|
||||
handler: function() {
|
||||
me.vm_command("resume", {});
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
// concat our item arrays and add them to the menu
|
||||
me.down('pveMenuButton').setMenuItems(top_items.concat(bottom_items));
|
||||
|
||||
},
|
||||
|
||||
initialize: function() {
|
||||
@ -217,5 +214,5 @@ Ext.define('PVE.VMSummaryBase', {
|
||||
me.reload();
|
||||
|
||||
this.callParent();
|
||||
}
|
||||
},
|
||||
});
|
||||
|
1415
www/mobile/WidgetToolkitUtils.js
Normal file
1415
www/mobile/WidgetToolkitUtils.js
Normal file
File diff suppressed because it is too large
Load Diff
@ -5,13 +5,13 @@ Ext.define('PVE.Page', {
|
||||
statics: {
|
||||
pathMatch: function(loc) {
|
||||
throw "implement this in subclass";
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
config: {
|
||||
layout: 'vbox',
|
||||
appUrl: undefined
|
||||
}
|
||||
appUrl: undefined,
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('PVE.ErrorPage', {
|
||||
@ -23,19 +23,20 @@ Ext.define('PVE.ErrorPage', {
|
||||
layout: {
|
||||
type: 'vbox',
|
||||
pack: 'center',
|
||||
align: 'stretch'
|
||||
align: 'stretch',
|
||||
},
|
||||
items: [
|
||||
{
|
||||
xtype: 'pveTitleBar',
|
||||
pveReloadButton: false,
|
||||
title: gettext('Error')
|
||||
}
|
||||
]
|
||||
}
|
||||
title: gettext('Error'),
|
||||
},
|
||||
],
|
||||
},
|
||||
});
|
||||
|
||||
Ext.define('PVE.Workspace', { statics: {
|
||||
Ext.define('PVE.Workspace', {
|
||||
statics: {
|
||||
// this class only contains static functions
|
||||
|
||||
loginData: null, // Data from last login call
|
||||
@ -44,16 +45,16 @@ Ext.define('PVE.Workspace', { statics: {
|
||||
|
||||
history: null,
|
||||
|
||||
pages: [
|
||||
pages: [
|
||||
'PVE.LXCMigrate',
|
||||
'PVE.LXCSummary',
|
||||
'PVE.QemuMigrate',
|
||||
'PVE.QemuSummary',
|
||||
'PVE.NodeSummary',
|
||||
'PVE.NodeSummary',
|
||||
'PVE.ClusterTaskList',
|
||||
'PVE.NodeTaskList',
|
||||
'PVE.TaskViewer',
|
||||
'PVE.Datacenter'
|
||||
'PVE.Datacenter',
|
||||
],
|
||||
|
||||
setHistory: function(h) {
|
||||
@ -72,7 +73,7 @@ Ext.define('PVE.Workspace', { statics: {
|
||||
lastAction = actions[actions.length - 2];
|
||||
|
||||
var url = '';
|
||||
if(lastAction) {
|
||||
if (lastAction) {
|
||||
actions.pop();
|
||||
url = lastAction.getUrl();
|
||||
}
|
||||
@ -82,7 +83,6 @@ Ext.define('PVE.Workspace', { statics: {
|
||||
},
|
||||
|
||||
__setAppWindow: function(comp, dir) {
|
||||
|
||||
var old = PVE.Workspace.appWindow;
|
||||
|
||||
PVE.Workspace.appWindow = comp;
|
||||
@ -95,7 +95,7 @@ Ext.define('PVE.Workspace', { statics: {
|
||||
Ext.Viewport.animateActiveItem(PVE.Workspace.appWindow, anim);
|
||||
}
|
||||
// remove old after anim (hack, because anim.after does not work in 2.3.1a)
|
||||
Ext.Function.defer(function(){
|
||||
Ext.Function.defer(function() {
|
||||
if (comp !== old) {
|
||||
Ext.Viewport.remove(old);
|
||||
}
|
||||
@ -123,8 +123,6 @@ Ext.define('PVE.Workspace', { statics: {
|
||||
},
|
||||
|
||||
gotoPage: function(loc) {
|
||||
var match;
|
||||
|
||||
var old = PVE.Workspace.appWindow;
|
||||
|
||||
if (old.getAppUrl) {
|
||||
@ -159,7 +157,7 @@ Ext.define('PVE.Workspace', { statics: {
|
||||
comp = Ext.create('PVE.ErrorPage', {});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
PVE.Workspace.__setAppWindow(comp, 'noanim');
|
||||
},
|
||||
|
||||
@ -170,18 +168,17 @@ Ext.define('PVE.Workspace', { statics: {
|
||||
if (done[item.key]) return;
|
||||
done[item.key] = 1;
|
||||
if (item.value) kv.push(item);
|
||||
}
|
||||
};
|
||||
|
||||
var keys = Ext.Array.sort(Ext.Object.getKeys(d));
|
||||
Ext.Array.each(names, function(k) {
|
||||
if (typeof(k) === 'object') {
|
||||
if (typeof k === 'object') {
|
||||
Ext.Array.each(keys, function(n) {
|
||||
if (k.test(n)) {
|
||||
pushItem({ key: n, value: d[n] });
|
||||
}
|
||||
});
|
||||
} else {
|
||||
|
||||
pushItem({ key: k, value: d[k] });
|
||||
}
|
||||
});
|
||||
@ -189,6 +186,7 @@ Ext.define('PVE.Workspace', { statics: {
|
||||
pushItem({ key: k, value: d[k] });
|
||||
});
|
||||
return kv;
|
||||
}
|
||||
},
|
||||
|
||||
}});
|
||||
},
|
||||
});
|
||||
|
@ -6,9 +6,9 @@ Ext.application({
|
||||
PVE.Workspace.setHistory(me.getHistory());
|
||||
|
||||
Ext.Ajax.on('requestexception', function(conn, response) {
|
||||
if (response.status === 401) {
|
||||
if (response.status === 401) {
|
||||
PVE.Workspace.showLogin();
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
});
|
||||
|
35
www/mobile/index.html.tpl
Normal file
35
www/mobile/index.html.tpl
Normal file
@ -0,0 +1,35 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>[% nodename %] - Proxmox Virtual Environment</title>
|
||||
|
||||
<link rel="icon" sizes="128x128" href="/pve2/images/logo-128.png" />
|
||||
<link rel="apple-touch-icon" sizes="128x128" href="/pve2/images/logo-128.png" />
|
||||
<link rel="stylesheet" type="text/css" href="/pve2/sencha-touch/resources/css/sencha-touch.css" />
|
||||
<link rel="stylesheet" type="text/css" href="/pve2/touch/pve.css?ver=[% version %]" />
|
||||
[% IF langfile %]
|
||||
<script type='text/javascript' src='/pve2/locale/pve-lang-[% lang %].js'></script>
|
||||
[% ELSE %]
|
||||
<script type="text/javascript">function gettext(buf) { return buf; }</script>
|
||||
[% END %]
|
||||
<script type="text/javascript">
|
||||
Proxmox = {
|
||||
Setup: { auth_cookie_name: 'PVEAuthCookie' },
|
||||
UserName: '[ % username %]',
|
||||
CSRFPreventionToken: '[% token %]'
|
||||
};
|
||||
</script>
|
||||
[%- IF debug %]
|
||||
<script type="text/javascript" src="/pve2/sencha-touch/sencha-touch-all-debug.js"></script>
|
||||
[%- ELSE %]
|
||||
<script type="text/javascript" src="/pve2/sencha-touch/sencha-touch-all.js"></script>
|
||||
[% END %]
|
||||
<script type="text/javascript" src="/pve2/touch/pvemanager-mobile.js?ver=[% version %]"></script>
|
||||
<script type="text/javascript">
|
||||
if (typeof(PVE) === 'undefined') PVE = {};
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
</body>
|
||||
</html>
|
1
www/mobile/pve.css
Normal file
1
www/mobile/pve.css
Normal file
@ -0,0 +1 @@
|
||||
/* currently empty */
|
Loading…
x
Reference in New Issue
Block a user