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

Method clear_apache_config

class/projectModel/pythonModel.py:2518–2529  ·  view source on GitHub ↗

@name 清除apache配置 @author hwliang<2021-08-09> @param project_find: dict<项目信息> @return bool

(self, project)

Source from the content-addressed store, hash-verified

2516 return True
2517
2518 def clear_apache_config(self, project):
2519 ''&#x27;
2520 @name 清除apache配置
2521 @author hwliang<2021-08-09>
2522 @param project_find: dict<项目信息>
2523 @return bool
2524 ''&#x27;
2525 project_name = project['name']
2526 config_file = "{}/apache/python_{}.conf".format(self._vhost_path, project_name)
2527 if os.path.exists(config_file):
2528 os.remove(config_file)
2529 return True
2530
2531 def get_project_find(self, project_name) -> Union[bool, dict]:
2532 ''&#x27;

Callers 1

clear_configMethod · 0.95

Calls 3

formatMethod · 0.45
existsMethod · 0.45
removeMethod · 0.45

Tested by

no test coverage detected