mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-08-19 01:30:21 +00:00
Add in version 1 and version 2 REST-API into zVM. Default zVM to version
1 in the zvmxcatws.cgi Change-Id: I2ad620ded8f4f3bff997bf308881cbeabd61022b
This commit is contained in:
@@ -347,6 +347,7 @@ cp xCAT-wsapi/* $RPM_BUILD_ROOT/%{prefix}/ws
|
||||
# xcatws.cgi causes xCAT-server requires perl-JSON, which is not shipped with PCM
|
||||
%if %pcm
|
||||
rm -f $RPM_BUILD_ROOT/%{prefix}/ws/xcatws.cgi
|
||||
rm -f $RPM_BUILD_ROOT/%{prefix}/ws/zvmxcatws.cgi
|
||||
%endif
|
||||
|
||||
%if %fsm
|
||||
@@ -354,8 +355,16 @@ rm -f $RPM_BUILD_ROOT/%{prefix}/ws/xcatws.cgi
|
||||
echo "ScriptAlias /xcatrhevh %{prefix}/ws/xcatrhevh.cgi" > $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache22
|
||||
echo "ScriptAlias /xcatrhevh %{prefix}/ws/xcatrhevh.cgi" > $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache24
|
||||
%if %notpcm
|
||||
%if %nots390x
|
||||
echo "ScriptAlias /xcatws %{prefix}/ws/xcatws.cgi" >> $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache22
|
||||
echo "ScriptAlias /xcatws %{prefix}/ws/xcatws.cgi" >> $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache24
|
||||
%else
|
||||
# Add in old version 1 REST-API and version 2 REST-API to z/VM, default to version 1
|
||||
echo "ScriptAlias /xcatwsv2 %{prefix}/ws/xcatws.cgi" >> $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache22
|
||||
echo "ScriptAlias /xcatwsv2 %{prefix}/ws/xcatws.cgi" >> $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache24
|
||||
echo "ScriptAlias /xcatws %{prefix}/ws/zvmxcatws.cgi" >> $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache22
|
||||
echo "ScriptAlias /xcatws %{prefix}/ws/zvmxcatws.cgi" >> $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache24
|
||||
%endif
|
||||
%endif
|
||||
|
||||
cat $RPM_BUILD_ROOT/%{prefix}/ws/xcat-ws.conf.apache22 >> $RPM_BUILD_ROOT/etc/%httpconfigdir/conf.orig/xcat-ws.conf.apache22
|
||||
|
@@ -5,8 +5,9 @@ RewriteEngine On
|
||||
RewriteCond %{SERVER_PORT} 80
|
||||
RewriteCond %{HTTPS} !=on
|
||||
RewriteRule ^/?xcatws/(.*) https://%{SERVER_NAME}/xcatws/$1 [R,L]
|
||||
RewriteRule ^/?xcatwsv2/(.*) https://%{SERVER_NAME}/xcatwsv2/$1 [R,L]
|
||||
|
||||
<Files xcatws.cgi>
|
||||
<Files (xcatws.cgi|zvmxcatws.cgi)>
|
||||
Order allow,deny
|
||||
Allow from all
|
||||
</Files>
|
||||
|
@@ -5,8 +5,9 @@ RewriteEngine On
|
||||
RewriteCond %{SERVER_PORT} 80
|
||||
RewriteCond %{HTTPS} !=on
|
||||
RewriteRule ^/?xcatws/(.*) https://%{SERVER_NAME}/xcatws/$1 [R,L]
|
||||
RewriteRule ^/?xcatwsv2/(.*) https://%{SERVER_NAME}/xcatwsv2/$1 [R,L]
|
||||
|
||||
<Files xcatws.cgi>
|
||||
<Files (xcatws.cgi|zvmxcatws.cgi)>
|
||||
Order allow,deny
|
||||
Allow from all
|
||||
</Files>
|
||||
|
@@ -3,8 +3,9 @@ RewriteEngine On
|
||||
RewriteCond %{SERVER_PORT} 80
|
||||
RewriteCond %{HTTPS} !=on
|
||||
RewriteRule ^/?xcatws/(.*) https://%{SERVER_NAME}/xcatws/$1 [R,L]
|
||||
RewriteRule ^/?xcatwsv2/(.*) https://%{SERVER_NAME}/xcatwsv2/$1 [R,L]
|
||||
|
||||
<Files xcatws.cgi>
|
||||
<Files (xcatws.cgi|zvmxcatws.cgi)>
|
||||
Require all granted
|
||||
</Files>
|
||||
|
||||
|
2521
xCAT-server/xCAT-wsapi/zvmxcatws.cgi
Normal file
2521
xCAT-server/xCAT-wsapi/zvmxcatws.cgi
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user