MCPcopy Create free account
hub / github.com/aaPanel/BaoTa / Set_Domain_path

Method Set_Domain_path

class/projectModel/javaModel.py:1609–1630  ·  view source on GitHub ↗
(self, domain, docBase)

Source from the content-addressed store, hash-verified

1607
1608 # 获取指定虚拟主机
1609 def Set_Domain_path(self, domain, docBase):
1610 try:
1611 Hosts = self.__ENGINE.getchildren()
1612 except:
1613 Hosts = list(self.__ENGINE)
1614 flag = False
1615 for host in Hosts:
1616 if host.tag != 'Host': continue
1617 if host.attrib['name'] == domain:
1618 try:
1619 ch = host.getchildren()
1620 except:
1621 ch = list(host)
1622 for i in ch:
1623 print(i.attrib)
1624 if 'docBase' in i.attrib:
1625 i.attrib['docBase'] = docBase
1626 flag = True
1627 if flag:
1628 self.save_tomcat()
1629 return True
1630 return False
1631
1632 def TomcatSetPath(self, port):
1633 '''

Callers 1

set_tomcat_duli_pathMethod · 0.95

Calls 1

save_tomcatMethod · 0.95

Tested by

no test coverage detected