cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bhais...@apache.org
Subject [cloudstack] 02/02: cloudstack-setup-mgmt: remove references of tomcat
Date Tue, 08 Aug 2017 09:23:03 GMT
This is an automated email from the ASF dual-hosted git repository.

bhaisaab pushed a commit to branch CLOUDSTACK-10012
in repository https://gitbox.apache.org/repos/asf/cloudstack.git

commit 7fb2b0bc00a5488390877981bd7267a5655e3f60
Author: Rohit Yadav <rohit.yadav@shapeblue.com>
AuthorDate: Tue Aug 8 11:22:42 2017 +0200

    cloudstack-setup-mgmt: remove references of tomcat
    
    Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
---
 python/lib/cloudutils/serviceConfigServer.py | 63 ----------------------------
 1 file changed, 63 deletions(-)

diff --git a/python/lib/cloudutils/serviceConfigServer.py b/python/lib/cloudutils/serviceConfigServer.py
index c975f6e..1184aca 100644
--- a/python/lib/cloudutils/serviceConfigServer.py
+++ b/python/lib/cloudutils/serviceConfigServer.py
@@ -83,63 +83,8 @@ class cloudManagementConfig(serviceCfgBase):
                 cfo = configFileOps("/etc/cloudstack/management/tomcat6.conf", self)
                 cfo.add_lines("JAVA_OPTS+=\" -Djavax.net.ssl.trustStore=%s \""%keyPath)
         elif self.syscfg.env.svrMode == "HttpsServer":
-            if self.syscfg.env.svrConf == "Tomcat7":
-                if not os.path.exists("/etc/cloudstack/management/server7-ssl.xml"):
-                    raise CloudRuntimeException("Cannot find /etc/cloudstack/management/server7-ssl.xml,
https enable failed")
-                if os.path.exists("/etc/cloudstack/management/server.xml"):
-                    bash("rm -f /etc/cloudstack/management/server.xml")
-                bash("ln -s /etc/cloudstack/management/server7-ssl.xml /etc/cloudstack/management/server.xml")
-                if os.path.exists("/usr/share/tomcat7/bin"):
-                    bash("rm -f /usr/share/cloudstack-management/bin")
-                    bash("ln -s /usr/share/tomcat7/bin /usr/share/cloudstack-management/bin")
-                if os.path.exists("/usr/share/tomcat7/lib"):
-                    bash("rm -f /usr/share/cloudstack-management/lib")
-                    bash("ln -s /usr/share/tomcat7/lib /usr/share/cloudstack-management/lib")
-            else:
-                if not os.path.exists("/etc/cloudstack/management/server-ssl.xml") or not
os.path.exists("/etc/cloudstack/management/tomcat6-ssl.conf"):
-                    raise CloudRuntimeException("Cannot find /etc/cloudstack/management/server-ssl.xml
or /etc/cloudstack/management/tomcat6-ssl.conf, https enable failed")
-                if os.path.exists("/etc/cloudstack/management/server.xml"):
-                    bash("rm -f /etc/cloudstack/management/server.xml")
-                if os.path.exists("/etc/cloudstack/management/tomcat6.conf"):
-                    bash("rm -f /etc/cloudstack/management/tomcat6.conf")
-                bash("ln -s /etc/cloudstack/management/server-ssl.xml /etc/cloudstack/management/server.xml")
-                bash("ln -s /etc/cloudstack/management/tomcat6-ssl.conf /etc/cloudstack/management/tomcat6.conf")
-                if os.path.exists("/usr/share/tomcat6/bin"):
-                    bash("rm -f /usr/share/cloudstack-management/bin")
-                    bash("ln -s /usr/share/tomcat6/bin /usr/share/cloudstack-management/bin")
-                if os.path.exists("/usr/share/tomcat6/lib"):
-                    bash("rm -f /usr/share/cloudstack-management/lib")
-                    bash("ln -s /usr/share/tomcat6/lib /usr/share/cloudstack-management/lib")
             if not bash("iptables-save |grep PREROUTING | grep 6443").isSuccess():
                 bash("iptables -A PREROUTING -t nat -p tcp --dport 443 -j REDIRECT --to-port
6443")
-        else:
-            if self.syscfg.env.svrConf == "Tomcat7":
-                if not os.path.exists("/etc/cloudstack/management/server7-nonssl.xml"):
-                    raise CloudRuntimeException("Cannot find /etc/cloudstack/management/server7-nonssl.xml,
https enable failed")
-                if os.path.exists("/etc/cloudstack/management/server.xml"):
-                    bash("rm -f /etc/cloudstack/management/server.xml")
-                bash("ln -s /etc/cloudstack/management/server7-nonssl.xml /etc/cloudstack/management/server.xml")
-                if os.path.exists("/usr/share/tomcat7/bin"):
-                    bash("rm -f /usr/share/cloudstack-management/bin")
-                    bash("ln -s /usr/share/tomcat7/bin /usr/share/cloudstack-management/bin")
-                if os.path.exists("/usr/share/tomcat7/lib"):
-                    bash("rm -f /usr/share/cloudstack-management/lib")
-                    bash("ln -s /usr/share/tomcat7/lib /usr/share/cloudstack-management/lib")
-            else:
-                if not os.path.exists("/etc/cloudstack/management/server-nonssl.xml") or
not os.path.exists("/etc/cloudstack/management/tomcat6-nonssl.conf"):
-                    raise CloudRuntimeException("Cannot find /etc/cloudstack/management/server-nonssl.xml
or /etc/cloudstack/management/tomcat6-nonssl.conf, https enable failed")
-                if os.path.exists("/etc/cloudstack/management/server.xml"):
-                    bash("rm -f /etc/cloudstack/management/server.xml")
-                if os.path.exists("/etc/cloudstack/management/tomcat6.conf"):
-                    bash("rm -f /etc/cloudstack/management/tomcat6.conf")
-                bash("ln -s /etc/cloudstack/management/server-nonssl.xml /etc/cloudstack/management/server.xml")
-                bash("ln -s /etc/cloudstack/management/tomcat6-nonssl.conf /etc/cloudstack/management/tomcat6.conf")
-                if os.path.exists("/usr/share/tomcat6/bin"):
-                    bash("rm -f /usr/share/cloudstack-management/bin")
-                    bash("ln -s /usr/share/tomcat6/bin /usr/share/cloudstack-management/bin")
-                if os.path.exists("/usr/share/tomcat6/lib"):
-                    bash("rm -f /usr/share/cloudstack-management/lib")
-                    bash("ln -s /usr/share/tomcat6/lib /usr/share/cloudstack-management/lib")
         bash("touch /var/run/cloudstack-management.pid")
         bash("chown cloud.cloud /var/run/cloudstack-management.pid")
         #distro like sl 6.1 needs this folder, or tomcat6 failed to start
@@ -153,14 +98,6 @@ class cloudManagementConfig(serviceCfgBase):
             cfo.add_lines("cloud hard nproc -1\n")
             cfo.save()
 
-        try:
-            if self.syscfg.env.svrConf == "Tomcat7":
-                self.syscfg.svo.disableService("tomcat")
-            else:
-                self.syscfg.svo.disableService("tomcat6")
-        except:
-            pass
-
         if self.syscfg.env.noStart == False:
             self.syscfg.svo.stopService("cloudstack-management")
             if self.syscfg.svo.enableService("cloudstack-management"):

-- 
To stop receiving notification emails like this one, please contact
"commits@cloudstack.apache.org" <commits@cloudstack.apache.org>.

Mime
View raw message