项目初始化
This commit is contained in:
@@ -17,7 +17,7 @@ import lombok.Setter;
|
|||||||
* </p>
|
* </p>
|
||||||
*
|
*
|
||||||
* @author gaoxq
|
* @author gaoxq
|
||||||
* @since 2025-08-23
|
* @since 2025-08-24
|
||||||
*/
|
*/
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@@ -66,6 +66,9 @@ public class DockerHost implements Serializable {
|
|||||||
@TableField("run_num")
|
@TableField("run_num")
|
||||||
private Long runNum;
|
private Long runNum;
|
||||||
|
|
||||||
|
@TableField("update_time")
|
||||||
|
private String updateTime;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 描述
|
* 描述
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ public class demo {
|
|||||||
.pathInfo(Collections.singletonMap(OutputFile.xml, System.getProperty("user.dir") + "/src/main/resources/mapper"));
|
.pathInfo(Collections.singletonMap(OutputFile.xml, System.getProperty("user.dir") + "/src/main/resources/mapper"));
|
||||||
})
|
})
|
||||||
.strategyConfig(builder -> {
|
.strategyConfig(builder -> {
|
||||||
builder.addInclude("biz_docker_container_info,biz_docker_host")
|
builder.addInclude("biz_docker_host")
|
||||||
.addTablePrefix("biz_")
|
.addTablePrefix("biz_")
|
||||||
.entityBuilder()
|
.entityBuilder()
|
||||||
.enableLombok()
|
.enableLombok()
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ import com.mini.capi.biz.service.SshUserService;
|
|||||||
import com.mini.capi.model.ApiResult;
|
import com.mini.capi.model.ApiResult;
|
||||||
import com.mini.capi.utils.HostRuntime;
|
import com.mini.capi.utils.HostRuntime;
|
||||||
import com.mini.capi.utils.docker;
|
import com.mini.capi.utils.docker;
|
||||||
|
import com.mini.capi.utils.vDate;
|
||||||
import jakarta.annotation.Resource;
|
import jakarta.annotation.Resource;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
@@ -158,6 +159,7 @@ public class sysController {
|
|||||||
.filter(d -> "1".equals(d.getStatus()))
|
.filter(d -> "1".equals(d.getStatus()))
|
||||||
.count();
|
.count();
|
||||||
host.setRunNum(count);
|
host.setRunNum(count);
|
||||||
|
host.setUpdateTime(vDate.getNow());
|
||||||
dockerHostService.updateById(host);
|
dockerHostService.updateById(host);
|
||||||
return ApiResult.success();
|
return ApiResult.success();
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
|||||||
Reference in New Issue
Block a user