From: XiaoPeng W. <xca...@so...> - 2015-03-26 11:16:30
|
The branch, master has been updated via aa7765accf0f01663577520ed655e1cb79883dce (commit) via 21204f4dde80f26f6073bf68207857c360460021 (commit) via f02a5e927d2e44f69ae7f29ad23686c4d75b6241 (commit) from b572fc52b41a8f298b7947fc7fec873224f5907d (commit) ----------------------------------------------------------------------- commit aa7765accf0f01663577520ed655e1cb79883dce Author: WangXiaoPeng <dan...@16...> Date: Thu Mar 26 06:17:17 2015 -0400 defect 4625: fix the issue that restapi does not work on Ubuntu commit 21204f4dde80f26f6073bf68207857c360460021 Author: WangXiaoPeng <dan...@16...> Date: Thu Mar 26 06:21:26 2015 -0400 fix the issue that POST - /networks does not work. and fix the ssl connection failure on ubuntu commit f02a5e927d2e44f69ae7f29ad23686c4d75b6241 Author: WangXiaoPeng <dan...@16...> Date: Thu Mar 26 07:12:23 2015 -0400 defect 4625: create necessary dirs for apache2 cfg ----------------------------------------------------------------------- diff --git a/xCAT-server/debian/dirs b/xCAT-server/debian/dirs index 93ede5a..7b29852 100644 --- a/xCAT-server/debian/dirs +++ b/xCAT-server/debian/dirs @@ -34,5 +34,6 @@ opt/xcat/xdsh/Context opt/xcat/ws etc/init.d etc/xcat -etc/apache2/conf.d +etc/apache2/conf-enabled +etc/apache2/conf-available opt/xcat/share/doc/packages/xCAT-server diff --git a/xCAT-server/debian/postrm b/xCAT-server/debian/postrm index d2b136a..4c92dbf 100644 --- a/xCAT-server/debian/postrm +++ b/xCAT-server/debian/postrm @@ -30,7 +30,7 @@ case "$1" in update-rc.d xcatd disable rm -f /usr/sbin/xcatd #remove the symbolic - rm -f /etc/apache2/conf.d/xcat-ws.conf + rm -f /etc/apache2/conf-enabled/xcat-ws.conf ;; *) diff --git a/xCAT-server/debian/rules b/xCAT-server/debian/rules index 410c07b..0275591 100755 --- a/xCAT-server/debian/rules +++ b/xCAT-server/debian/rules @@ -66,9 +66,10 @@ binary-arch: chmod 644 $(rootdir)/lib/perl/xCAT_schema/samples/* chmod 644 $(rootdir)/lib/shfunctions chmod 644 $(rootdir)/share/doc/packages/xCAT-server/* - echo "ScriptAlias /xcatws $(prefix)/ws/xcatws.cgi" > $(buildroot)/etc/apache2/conf.d/xcat-ws.conf - cat $(PWD)/xCAT-wsapi/xcat-ws.conf.ubuntu >> $(buildroot)/etc/apache2/conf.d/xcat-ws.conf + echo "ScriptAlias /xcatws $(prefix)/ws/xcatws.cgi" > $(buildroot)/etc/apache2/conf-available/xcat-ws.conf + cat $(PWD)/xCAT-wsapi/xcat-ws.conf.ubuntu >> $(buildroot)/etc/apache2/conf-available/xcat-ws.conf rm -rf $(rootdir)/ws/xcat-ws.conf* + ln -s ../conf-available/xcat-ws.conf $(buildroot)/etc/apache2/conf-enabled/xcat-ws.conf # dh_installmenu # dh_installdebconf # dh_installlogrotate diff --git a/xCAT-server/xCAT-wsapi/xcat-ws.conf.ubuntu b/xCAT-server/xCAT-wsapi/xcat-ws.conf.ubuntu index 48ef8bb..1609e71 100644 --- a/xCAT-server/xCAT-wsapi/xcat-ws.conf.ubuntu +++ b/xCAT-server/xCAT-wsapi/xcat-ws.conf.ubuntu @@ -1,11 +1,11 @@ LoadModule rewrite_module /usr/lib/apache2/modules/mod_rewrite.so +LoadModule cgi_module /usr/lib/apache2/modules/mod_cgi.so RewriteEngine On RewriteCond %{SERVER_PORT} 80 RewriteCond %{REQUEST_URI} xcatws RewriteRule ^(.*)$ https://%{SERVER_NAME}$1 [R,L] <Files xcatws.cgi> - Order allow,deny - Allow from all + Require all granted </Files> diff --git a/xCAT-server/xCAT-wsapi/xcatws.cgi b/xCAT-server/xCAT-wsapi/xcatws.cgi index 32f6818..70c5123 100755 --- a/xCAT-server/xCAT-wsapi/xcatws.cgi +++ b/xCAT-server/xCAT-wsapi/xcatws.cgi @@ -728,6 +728,7 @@ my %URIdef = ( example => "|Create the networks resources base on the network configuration on xCAT MN.|POST|/networks||", cmd => "makenetworks", fhandler => \&actionhdl, + outhdler => \&noout, }, }, network_allattr => { @@ -2674,6 +2675,7 @@ sub sendRequest { else { $client = IO::Socket::SSL->new( PeerAddr => $xcatHost, + SSL_verify_mode => 0, Timeout => 15,); } unless ($client) { |