首页接口重构
This commit is contained in:
@@ -18,6 +18,13 @@ export interface ServerInfo extends BasicModel<ServerInfo> {
|
||||
containerId: string; // 容器ID
|
||||
}
|
||||
|
||||
export interface SystemInfo extends BasicModel<SystemInfo> {
|
||||
cpu: string; // CPU使用率
|
||||
memory: string; // 内存
|
||||
disk: string; // 磁盘
|
||||
}
|
||||
|
||||
|
||||
export interface ContainerInfo extends BasicModel<ContainerInfo> {
|
||||
image: string; // 镜像名称
|
||||
command: string; // 启动命令
|
||||
@@ -42,6 +49,9 @@ defHttp.get<ServerInfo[]>({ url: adminPath + '/docker/myServer/listAll' });
|
||||
export const myContainerInfo = (params?: ContainerInfo | any) =>
|
||||
defHttp.get<ContainerInfo[]>({ url: adminPath + '/docker/myContainer/listAll', params });
|
||||
|
||||
export const mySystemInfo = (params?: ContainerInfo | any) =>
|
||||
defHttp.get<SystemInfo>({ url: adminPath + '/docker/myContainer/systemInfo', params });
|
||||
|
||||
export const myDockerStop = (params?: ContainerInfo | any) =>
|
||||
defHttp.get<DockerResult>({ url: adminPath + '/docker/myContainer/stop', params });
|
||||
|
||||
|
||||
Reference in New Issue
Block a user