[pve-devel] r6093 - in pve-manager/pve2: . debian lib/PVE www/templates
svn-commits at proxmox.com
svn-commits at proxmox.com
Thu Jun 16 14:51:15 CEST 2011
Author: dietmar
Date: 2011-06-16 14:51:15 +0200 (Thu, 16 Jun 2011)
New Revision: 6093
Added:
pve-manager/pve2/www/templates/pve-redirect.conf
Modified:
pve-manager/pve2/ChangeLog
pve-manager/pve2/debian/conffiles
pve-manager/pve2/lib/PVE/API2Client.pm
pve-manager/pve2/lib/PVE/REST.pm
pve-manager/pve2/www/templates/Makefile.am
pve-manager/pve2/www/templates/pve.conf.in
Log:
change port to 8006
Modified: pve-manager/pve2/ChangeLog
===================================================================
--- pve-manager/pve2/ChangeLog 2011-06-16 12:03:11 UTC (rev 6092)
+++ pve-manager/pve2/ChangeLog 2011-06-16 12:51:15 UTC (rev 6093)
@@ -1,3 +1,10 @@
+2011-06-16 Proxmox Support Team <support at proxmox.com>
+
+ * www/templates/pve-redirect.conf: allow optional redirect from
+ port 80 (a2enmod pve-redirect.conf)
+
+ * www/templates/pve.conf.in: change API management port to 8006
+
2011-05-23 Proxmox Support Team <support at proxmox.com>
* lib/PVE/APIDaemon.pm (send_error): use CGI instead of HTTP::Request::Params
Modified: pve-manager/pve2/debian/conffiles
===================================================================
--- pve-manager/pve2/debian/conffiles 2011-06-16 12:03:11 UTC (rev 6092)
+++ pve-manager/pve2/debian/conffiles 2011-06-16 12:51:15 UTC (rev 6093)
@@ -4,5 +4,6 @@
/etc/init.d/pvestatd
/etc/cron.daily/pve
/etc/apache2/sites-available/pve.conf
+/etc/apache2/sites-available/pve-redirect.conf
/etc/vz/conf/ve-pve.auto.conf-sample
/etc/vz/vznet.conf
Modified: pve-manager/pve2/lib/PVE/API2Client.pm
===================================================================
--- pve-manager/pve2/lib/PVE/API2Client.pm 2011-06-16 12:03:11 UTC (rev 6092)
+++ pve-manager/pve2/lib/PVE/API2Client.pm 2011-06-16 12:51:15 UTC (rev 6093)
@@ -120,7 +120,7 @@
bless $self;
if (!$self->{port}) {
- $self->{port} = $self->{host} eq 'localhost' ? 85 : 443;
+ $self->{port} = $self->{host} eq 'localhost' ? 85 : 8006;
}
if (!$self->{protocol}) {
$self->{protocol} = $self->{host} eq 'localhost' ? 'http' : 'https';
Modified: pve-manager/pve2/lib/PVE/REST.pm
===================================================================
--- pve-manager/pve2/lib/PVE/REST.pm 2011-06-16 12:03:11 UTC (rev 6092)
+++ pve-manager/pve2/lib/PVE/REST.pm 2011-06-16 12:51:15 UTC (rev 6093)
@@ -202,7 +202,7 @@
} else {
$uri->scheme('https');
$uri->host($host);
- $uri->port(443);
+ $uri->port(8006);
}
$uri->path($abs_uri);
Modified: pve-manager/pve2/www/templates/Makefile.am
===================================================================
--- pve-manager/pve2/www/templates/Makefile.am 2011-06-16 12:03:11 UTC (rev 6092)
+++ pve-manager/pve2/www/templates/Makefile.am 2011-06-16 12:51:15 UTC (rev 6093)
@@ -6,7 +6,7 @@
mv $@.tmp $@
-apache_DATA = $(BUILDDATA)
+apache_DATA = $(BUILDDATA) pve-redirect.conf
apachedir = /etc/apache2/sites-available/
Added: pve-manager/pve2/www/templates/pve-redirect.conf
===================================================================
--- pve-manager/pve2/www/templates/pve-redirect.conf (rev 0)
+++ pve-manager/pve2/www/templates/pve-redirect.conf 2011-06-16 12:51:15 UTC (rev 6093)
@@ -0,0 +1,8 @@
+<VirtualHost *:80>
+ #RewriteLog "/root/rewrite.log"
+ #RewriteLogLevel 10
+ RewriteEngine on
+ RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
+ RewriteRule .* - [F]
+ RewriteRule ^/(.*) https://%{HTTP_HOST}:8006/$1 [L,R]
+</VirtualHost>
Modified: pve-manager/pve2/www/templates/pve.conf.in
===================================================================
--- pve-manager/pve2/www/templates/pve.conf.in 2011-06-16 12:03:11 UTC (rev 6092)
+++ pve-manager/pve2/www/templates/pve.conf.in 2011-06-16 12:51:15 UTC (rev 6093)
@@ -19,50 +19,18 @@
KeepAlive Off
-DocumentRoot @WWW_ROOTDIR@
-<Directory />
- Options FollowSymLinks
- AllowOverride None
-</Directory>
-
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE application/json
</IfModule>
-<Directory @WWW_ROOTDIR@>
- Options FollowSymLinks MultiViews
- AllowOverride None
- Order allow,deny
- allow from all
-</Directory>
-
ErrorLog /var/log/apache2/error.log
LogLevel warn
CustomLog /var/log/apache2/access.log combined
-Alias /pve2/ @WWW_BASEDIR@/
-Alias /vncterm/ /usr/share/vncterm/
-
-# avoid authentication when accessing favicon
-Alias /favicon.ico @WWW_IMAGEDIR@/favicon.ico
-
-PerlRequire @WWW_BASEDIR@/startup.pl
-
-<Location /index.pl>
- SetHandler perl-script
- PerlHandler ModPerl::Registry
- Options ExecCGI
-</Location>
-
-<Location /api2/>
- SetHandler perl-script
- PerlHandler PVE::REST
-</Location>
-
-<VirtualHost *:443>
-
+Listen 8006
+<VirtualHost *:8006>
SSLEngine on
SSLProtocol all -SSLv2
SSLCertificateFile @PROXMOX_ETC@/local/pve-ssl.pem
@@ -72,14 +40,37 @@
RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
RewriteRule .* - [F]
- </VirtualHost>
+ DocumentRoot @WWW_ROOTDIR@
+ <Directory />
+ Options FollowSymLinks
+ AllowOverride None
+ </Directory>
-<VirtualHost *:80>
- #RewriteLog "/root/rewrite.log"
- #RewriteLogLevel 10
- RewriteEngine on
- RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
- RewriteRule .* - [F]
- RewriteRule ^/(.*) https://%{HTTP_HOST}/$1 [L,R]
+ <Directory @WWW_ROOTDIR@>
+ Options FollowSymLinks MultiViews
+ AllowOverride None
+ Order allow,deny
+ allow from all
+ </Directory>
+
+ Alias /pve2/ @WWW_BASEDIR@/
+ Alias /vncterm/ /usr/share/vncterm/
+
+ # avoid authentication when accessing favicon
+ Alias /favicon.ico @WWW_IMAGEDIR@/favicon.ico
+
+ PerlRequire @WWW_BASEDIR@/startup.pl
+
+ <Location /index.pl>
+ SetHandler perl-script
+ PerlHandler ModPerl::Registry
+ Options ExecCGI
+ </Location>
+
+ <Location /api2/>
+ SetHandler perl-script
+ PerlHandler PVE::REST
+ </Location>
+
</VirtualHost>
More information about the pve-devel
mailing list