Commit 2333961c authored by 金凯强's avatar 金凯强 🎨

还原接口配置

parent 08f5aa05
......@@ -8,13 +8,13 @@ from app.info.info_service import InfoService
@api('info')
class InfoAPI(ApiController):
@api('app_list/<string:project_no>')
def get_app_list(self, project_no):
@api('app_list')
def get_app_list(self):
'''
获取app_list
:return:
'''
return InfoService().get_app_list(project_no)
return InfoService().get_app_list()
@api('app_upgrade')
def post_set_app_upgrade_info(self):
......
......@@ -21,14 +21,8 @@ docker_client = docker.APIClient(base_url='unix:///var/run/docker.sock')
class InfoService(HSBaseUCService):
def get_app_list(self, project_no):
project_info = ConnectionService().get_project_info(project_no)
if not project_info:
# raise HSException('请先设置项目信息')
return []
host_ip = project_info.get('host_ip')
# host_ip = 'localhost'
def get_app_list(self):
host_ip = 'localhost'
containers = docker_client.containers()
app_info_list = []
for container in containers:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment