1.31 k8s开发

This commit is contained in:
dengqichen 2025-12-15 13:28:16 +08:00
parent 7cbc1359b3
commit 8c9aec2e0c
8 changed files with 279 additions and 64 deletions

View File

@ -22,15 +22,24 @@ public class K8sDeploymentDTO extends BaseDTO {
@Schema(description = "Deployment名称") @Schema(description = "Deployment名称")
private String deploymentName; private String deploymentName;
@Schema(description = "期望副本数") @Schema(description = "期望副本数来自spec.replicas用户声明的目标副本数")
private Integer replicas; private Integer desiredReplicas;
@Schema(description = "可用副本数") @Schema(description = "当前副本数来自status.replicas所有Pod总数包括Running/Pending/Failed等所有状态")
private Integer currentReplicas;
@Schema(description = "可用副本数来自status.availableReplicasReady且可接收流量的Pod数")
private Integer availableReplicas; private Integer availableReplicas;
@Schema(description = "就绪副本数") @Schema(description = "就绪副本数来自status.readyReplicas健康检查通过的Pod数")
private Integer readyReplicas; private Integer readyReplicas;
@Schema(description = "已更新副本数来自status.updatedReplicas已更新到最新版本的Pod数")
private Integer updatedReplicas;
@Schema(description = "不可用副本数来自status.unavailableReplicas不可用的Pod数")
private Integer unavailableReplicas;
@Schema(description = "总重启次数所有Pod的重启次数总和") @Schema(description = "总重启次数所有Pod的重启次数总和")
private Integer totalRestartCount; private Integer totalRestartCount;

View File

@ -29,15 +29,51 @@ public class K8sDeployment extends Entity<Long> {
@Column(name = "deployment_name", nullable = false) @Column(name = "deployment_name", nullable = false)
private String deploymentName; private String deploymentName;
@Column(name = "replicas") /**
private Integer replicas; * 期望副本数来自spec.replicas
* 用户声明的目标副本数
*/
@Column(name = "desired_replicas")
private Integer desiredReplicas;
/**
* 当前副本数来自status.replicas
* 所有Pod总数包括Running/Pending/Failed等所有状态
*/
@Column(name = "current_replicas")
private Integer currentReplicas;
/**
* 可用副本数来自status.availableReplicas
* Ready且可接收流量的Pod数
*/
@Column(name = "available_replicas") @Column(name = "available_replicas")
private Integer availableReplicas; private Integer availableReplicas;
/**
* 就绪副本数来自status.readyReplicas
* 健康检查通过的Pod数
*/
@Column(name = "ready_replicas") @Column(name = "ready_replicas")
private Integer readyReplicas; private Integer readyReplicas;
/**
* 已更新副本数来自status.updatedReplicas
* 已更新到最新版本的Pod数
*/
@Column(name = "updated_replicas")
private Integer updatedReplicas;
/**
* 不可用副本数来自status.unavailableReplicas
* 不可用的Pod数
*/
@Column(name = "unavailable_replicas")
private Integer unavailableReplicas;
/**
* 总重启次数所有Pod的重启次数总和
*/
@Column(name = "total_restart_count") @Column(name = "total_restart_count")
private Integer totalRestartCount; private Integer totalRestartCount;

View File

@ -196,13 +196,18 @@ public class K8sServiceIntegrationImpl extends BaseExternalSystemIntegration imp
response.setName(deployment.getMetadata().getName()); response.setName(deployment.getMetadata().getName());
response.setNamespace(deployment.getMetadata().getNamespace()); response.setNamespace(deployment.getMetadata().getNamespace());
// 从spec读取期望副本数
if (deployment.getSpec() != null) { if (deployment.getSpec() != null) {
response.setReplicas(deployment.getSpec().getReplicas()); response.setDesiredReplicas(deployment.getSpec().getReplicas());
} }
// 从status读取实际状态
if (deployment.getStatus() != null) { if (deployment.getStatus() != null) {
response.setCurrentReplicas(deployment.getStatus().getReplicas());
response.setAvailableReplicas(deployment.getStatus().getAvailableReplicas()); response.setAvailableReplicas(deployment.getStatus().getAvailableReplicas());
response.setReadyReplicas(deployment.getStatus().getReadyReplicas()); response.setReadyReplicas(deployment.getStatus().getReadyReplicas());
response.setUpdatedReplicas(deployment.getStatus().getUpdatedReplicas());
response.setUnavailableReplicas(deployment.getStatus().getUnavailableReplicas());
} }
response.setLabels(deployment.getMetadata().getLabels()); response.setLabels(deployment.getMetadata().getLabels());
@ -212,12 +217,9 @@ public class K8sServiceIntegrationImpl extends BaseExternalSystemIntegration imp
} }
// 获取第一个容器的镜像 // 获取第一个容器的镜像
if (deployment.getSpec() != null String image = extractFirstContainerImage(deployment);
&& deployment.getSpec().getTemplate() != null if (image != null) {
&& deployment.getSpec().getTemplate().getSpec() != null response.setImage(image);
&& deployment.getSpec().getTemplate().getSpec().getContainers() != null
&& !deployment.getSpec().getTemplate().getSpec().getContainers().isEmpty()) {
response.setImage(deployment.getSpec().getTemplate().getSpec().getContainers().get(0).getImage());
} }
if (deployment.getMetadata().getCreationTimestamp() != null) { if (deployment.getMetadata().getCreationTimestamp() != null) {
@ -273,13 +275,18 @@ public class K8sServiceIntegrationImpl extends BaseExternalSystemIntegration imp
response.setName(deployment.getMetadata().getName()); response.setName(deployment.getMetadata().getName());
response.setNamespace(deployment.getMetadata().getNamespace()); response.setNamespace(deployment.getMetadata().getNamespace());
// 从spec读取期望副本数
if (deployment.getSpec() != null) { if (deployment.getSpec() != null) {
response.setReplicas(deployment.getSpec().getReplicas()); response.setDesiredReplicas(deployment.getSpec().getReplicas());
} }
// 从status读取实际状态
if (deployment.getStatus() != null) { if (deployment.getStatus() != null) {
response.setCurrentReplicas(deployment.getStatus().getReplicas());
response.setAvailableReplicas(deployment.getStatus().getAvailableReplicas()); response.setAvailableReplicas(deployment.getStatus().getAvailableReplicas());
response.setReadyReplicas(deployment.getStatus().getReadyReplicas()); response.setReadyReplicas(deployment.getStatus().getReadyReplicas());
response.setUpdatedReplicas(deployment.getStatus().getUpdatedReplicas());
response.setUnavailableReplicas(deployment.getStatus().getUnavailableReplicas());
} }
response.setLabels(deployment.getMetadata().getLabels()); response.setLabels(deployment.getMetadata().getLabels());
@ -289,12 +296,9 @@ public class K8sServiceIntegrationImpl extends BaseExternalSystemIntegration imp
} }
// 获取第一个容器的镜像 // 获取第一个容器的镜像
if (deployment.getSpec() != null String image = extractFirstContainerImage(deployment);
&& deployment.getSpec().getTemplate() != null if (image != null) {
&& deployment.getSpec().getTemplate().getSpec() != null response.setImage(image);
&& deployment.getSpec().getTemplate().getSpec().getContainers() != null
&& !deployment.getSpec().getTemplate().getSpec().getContainers().isEmpty()) {
response.setImage(deployment.getSpec().getTemplate().getSpec().getContainers().get(0).getImage());
} }
if (deployment.getMetadata().getCreationTimestamp() != null) { if (deployment.getMetadata().getCreationTimestamp() != null) {
@ -486,7 +490,7 @@ public class K8sServiceIntegrationImpl extends BaseExternalSystemIntegration imp
} }
// 容器状态 // 容器状态
if (pod.getStatus().getContainerStatuses() != null) { if (pod.getStatus().getContainerStatuses() != null && !pod.getStatus().getContainerStatuses().isEmpty()) {
List<K8sPodResponse.ContainerInfo> containers = new ArrayList<>(); List<K8sPodResponse.ContainerInfo> containers = new ArrayList<>();
int totalRestartCount = 0; int totalRestartCount = 0;
boolean allReady = true; boolean allReady = true;
@ -535,6 +539,11 @@ public class K8sServiceIntegrationImpl extends BaseExternalSystemIntegration imp
response.setContainers(containers); response.setContainers(containers);
response.setRestartCount(totalRestartCount); response.setRestartCount(totalRestartCount);
response.setReady(allReady); response.setReady(allReady);
} else {
// Failed/Evicted状态的Pod可能没有containerStatuses
// 设置默认值确保统计信息完整
response.setRestartCount(0);
response.setReady(false);
} }
} }
@ -542,40 +551,8 @@ public class K8sServiceIntegrationImpl extends BaseExternalSystemIntegration imp
if (pod.getSpec() != null) { if (pod.getSpec() != null) {
response.setNodeName(pod.getSpec().getNodeName()); response.setNodeName(pod.getSpec().getNodeName());
// 容器资源配置 // 填充容器资源配置
if (pod.getSpec().getContainers() != null && response.getContainers() != null) { fillContainerResources(pod.getSpec().getContainers(), response.getContainers());
for (int i = 0; i < pod.getSpec().getContainers().size() && i < response.getContainers().size(); i++) {
V1Container container = pod.getSpec().getContainers().get(i);
K8sPodResponse.ContainerInfo containerInfo = response.getContainers().get(i);
if (container.getResources() != null) {
if (container.getResources().getRequests() != null) {
containerInfo.setCpuRequest(
container.getResources().getRequests().get("cpu") != null
? container.getResources().getRequests().get("cpu").toSuffixedString()
: null
);
containerInfo.setMemoryRequest(
container.getResources().getRequests().get("memory") != null
? container.getResources().getRequests().get("memory").toSuffixedString()
: null
);
}
if (container.getResources().getLimits() != null) {
containerInfo.setCpuLimit(
container.getResources().getLimits().get("cpu") != null
? container.getResources().getLimits().get("cpu").toSuffixedString()
: null
);
containerInfo.setMemoryLimit(
container.getResources().getLimits().get("memory") != null
? container.getResources().getLimits().get("memory").toSuffixedString()
: null
);
}
}
}
}
} }
// Owner信息 // Owner信息
@ -886,4 +863,108 @@ public class K8sServiceIntegrationImpl extends BaseExternalSystemIntegration imp
client.setReadTimeout(120000); // 120秒读取超时优化日志查询等耗时操作 client.setReadTimeout(120000); // 120秒读取超时优化日志查询等耗时操作
return client; return client;
} }
/**
* 提取Deployment中第一个容器的镜像
*
* @param deployment K8s Deployment对象
* @return 镜像名称如果不存在则返回null
*/
private String extractFirstContainerImage(V1Deployment deployment) {
if (deployment.getSpec() == null) {
return null;
}
V1PodTemplateSpec template = deployment.getSpec().getTemplate();
if (template == null) {
return null;
}
V1PodSpec podSpec = template.getSpec();
if (podSpec == null) {
return null;
}
List<V1Container> containers = podSpec.getContainers();
if (containers == null || containers.isEmpty()) {
return null;
}
return containers.get(0).getImage();
}
/**
* 填充容器资源配置信息
*
* @param specContainers Pod Spec中的容器列表
* @param containerInfos 响应对象中的容器信息列表
*/
private void fillContainerResources(List<V1Container> specContainers, List<K8sPodResponse.ContainerInfo> containerInfos) {
if (specContainers == null || containerInfos == null) {
return;
}
int size = Math.min(specContainers.size(), containerInfos.size());
for (int i = 0; i < size; i++) {
V1Container container = specContainers.get(i);
K8sPodResponse.ContainerInfo containerInfo = containerInfos.get(i);
V1ResourceRequirements resources = container.getResources();
if (resources == null) {
continue;
}
// 填充资源请求requests
fillResourceRequests(resources, containerInfo);
// 填充资源限制limits
fillResourceLimits(resources, containerInfo);
}
}
/**
* 填充容器资源请求配置
*
* @param resources 资源配置对象
* @param containerInfo 容器信息对象
*/
private void fillResourceRequests(V1ResourceRequirements resources, K8sPodResponse.ContainerInfo containerInfo) {
Map<String, io.kubernetes.client.custom.Quantity> requests = resources.getRequests();
if (requests == null) {
return;
}
io.kubernetes.client.custom.Quantity cpu = requests.get("cpu");
if (cpu != null) {
containerInfo.setCpuRequest(cpu.toSuffixedString());
}
io.kubernetes.client.custom.Quantity memory = requests.get("memory");
if (memory != null) {
containerInfo.setMemoryRequest(memory.toSuffixedString());
}
}
/**
* 填充容器资源限制配置
*
* @param resources 资源配置对象
* @param containerInfo 容器信息对象
*/
private void fillResourceLimits(V1ResourceRequirements resources, K8sPodResponse.ContainerInfo containerInfo) {
Map<String, io.kubernetes.client.custom.Quantity> limits = resources.getLimits();
if (limits == null) {
return;
}
io.kubernetes.client.custom.Quantity cpu = limits.get("cpu");
if (cpu != null) {
containerInfo.setCpuLimit(cpu.toSuffixedString());
}
io.kubernetes.client.custom.Quantity memory = limits.get("memory");
if (memory != null) {
containerInfo.setMemoryLimit(memory.toSuffixedString());
}
}
} }

View File

@ -5,14 +5,73 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
import java.util.Map; import java.util.Map;
/**
* K8s Deployment响应对象
*
* <p>字段说明参考kubectl get deployment输出
* <pre>
* NAME READY UP-TO-DATE AVAILABLE AGE
* my-app 2/2 2 2 5d
*
* readyReplicas/desiredReplicas updatedReplicas availableReplicas
* </pre>
*
* <p>副本数字段完整映射K8s API
* <ul>
* <li>desiredReplicas: 期望副本数来自spec.replicas用户声明的目标副本数</li>
* <li>currentReplicas: 当前副本数来自status.replicas所有Pod总数包括Running/Pending/Failed等所有状态</li>
* <li>availableReplicas: 可用副本数来自status.availableReplicasReady且可接收流量的Pod数</li>
* <li>readyReplicas: 就绪副本数来自status.readyReplicas健康检查通过的Pod数</li>
* <li>updatedReplicas: 已更新副本数来自status.updatedReplicas已更新到最新版本的Pod数</li>
* <li>unavailableReplicas: 不可用副本数来自status.unavailableReplicas不可用的Pod数</li>
* </ul>
*/
@Data @Data
public class K8sDeploymentResponse { public class K8sDeploymentResponse {
private String name; private String name;
private String namespace; private String namespace;
private Integer replicas;
/**
* 期望副本数来自spec.replicas
* 用户声明的目标副本数
*/
private Integer desiredReplicas;
/**
* 当前副本数来自status.replicas
* 所有Pod总数包括Running/Pending/Failed等所有状态
*/
private Integer currentReplicas;
/**
* 可用副本数来自status.availableReplicas
* Ready且可接收流量的Pod数
*/
private Integer availableReplicas; private Integer availableReplicas;
/**
* 就绪副本数来自status.readyReplicas
* 健康检查通过的Pod数
*/
private Integer readyReplicas; private Integer readyReplicas;
/**
* 已更新副本数来自status.updatedReplicas
* 已更新到最新版本的Pod数
*/
private Integer updatedReplicas;
/**
* 不可用副本数来自status.unavailableReplicas
* 不可用的Pod数
*/
private Integer unavailableReplicas;
/**
* 总重启次数所有Pod的重启次数总和
*/
private Integer totalRestartCount; private Integer totalRestartCount;
private String image; private String image;
private Map<String, String> labels; private Map<String, String> labels;
private Map<String, String> selector; private Map<String, String> selector;

View File

@ -116,9 +116,12 @@ public class K8sDeploymentServiceImpl extends BaseServiceImpl<K8sDeployment, K8s
log.debug("更新Deployment: {}", response.getName()); log.debug("更新Deployment: {}", response.getName());
} }
deployment.setReplicas(response.getReplicas()); deployment.setDesiredReplicas(response.getDesiredReplicas());
deployment.setCurrentReplicas(response.getCurrentReplicas());
deployment.setAvailableReplicas(response.getAvailableReplicas()); deployment.setAvailableReplicas(response.getAvailableReplicas());
deployment.setReadyReplicas(response.getReadyReplicas()); deployment.setReadyReplicas(response.getReadyReplicas());
deployment.setUpdatedReplicas(response.getUpdatedReplicas());
deployment.setUnavailableReplicas(response.getUnavailableReplicas());
deployment.setImage(response.getImage()); deployment.setImage(response.getImage());
deployment.setLabels(response.getLabels()); deployment.setLabels(response.getLabels());
deployment.setSelector(response.getSelector()); deployment.setSelector(response.getSelector());
@ -342,8 +345,8 @@ public class K8sDeploymentServiceImpl extends BaseServiceImpl<K8sDeployment, K8s
replicas replicas
); );
// 5. 更新本地数据库记录 // 5. 更新本地数据库记录更新期望副本数
deployment.setReplicas(replicas); deployment.setDesiredReplicas(replicas);
k8sDeploymentRepository.save(deployment); k8sDeploymentRepository.save(deployment);
log.info("Deployment扩缩容成功deploymentId: {}, replicas: {}", deploymentId, replicas); log.info("Deployment扩缩容成功deploymentId: {}, replicas: {}", deploymentId, replicas);

View File

@ -716,7 +716,7 @@ INSERT INTO `deploy-ease-platform`.`deploy_environment` (`id`, `tenant_code`, `e
INSERT INTO `deploy-ease-platform`.`deploy_team` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_code`, `team_name`, `description`, `owner_id`, `owner_name`, `enabled`, `sort`, `development_mode`, `enable_git_sync_check`) VALUES (3, 'admin', NOW(), 'admin', NOW(), 1, b'0', 'DP_SCP', '需求计划', '', 1, '超级管理员', b'1', 0, 'STANDARD', b'0'); INSERT INTO `deploy-ease-platform`.`deploy_team` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_code`, `team_name`, `description`, `owner_id`, `owner_name`, `enabled`, `sort`, `development_mode`, `enable_git_sync_check`) VALUES (3, 'admin', NOW(), 'admin', NOW(), 1, b'0', 'DP_SCP', '需求计划', '', 1, '超级管理员', b'1', 0, 'STANDARD', b'0');
INSERT INTO `deploy-ease-platform`.`deploy_team` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_code`, `team_name`, `description`, `owner_id`, `owner_name`, `enabled`, `sort`, `development_mode`, `enable_git_sync_check`) VALUES (4, 'admin', NOW(), 'admin', NOW(), 2, b'0', 'DL_SCP_LONGI', '隆基项目', '', 1, '超级管理员', b'1', 0, 'SYNC_MODE', b'1'); INSERT INTO `deploy-ease-platform`.`deploy_team` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_code`, `team_name`, `description`, `owner_id`, `owner_name`, `enabled`, `sort`, `development_mode`, `enable_git_sync_check`) VALUES (4, 'admin', NOW(), 'admin', NOW(), 2, b'0', 'DL_SCP_LONGI', '隆基项目', '', 1, '超级管理员', b'1', 0, 'SYNC_MODE', b'1');
INSERT INTO `deploy-ease-platform`.`deploy_team` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_code`, `team_name`, `description`, `owner_id`, `owner_name`, `enabled`, `sort`, `development_mode`, `enable_git_sync_check`) VALUES (5, 'admin', NOW(), 'admin', NOW(), 3, b'0', 'LOCALIZATION', '国产化改造', '', 1, '超级管理员', b'1', 0, 'STANDARD', b'0'); INSERT INTO `deploy-ease-platform`.`deploy_team` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_code`, `team_name`, `description`, `owner_id`, `owner_name`, `enabled`, `sort`, `development_mode`, `enable_git_sync_check`) VALUES (5, 'admin', NOW(), 'admin', NOW(), 3, b'0', 'LOCALIZATION', '国产化改造', '', 1, '超级管理员', b'1', 0, 'STANDARD', b'0');
INSERT INTO `deploy-ease-platform`.`deploy_team` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_code`, `team_name`, `description`, `owner_id`, `owner_name`, `enabled`, `sort`, `development_mode`, `enable_git_sync_check`) VALUES (6, 'admin', NOW(), 'admin', NOW(), 1, b'0', 'SCP_ORDER', '订单团队', '', NULL, '', b'1', 0, 'STANDARD', b'0'); INSERT INTO `deploy-ease-platform`.`deploy_team` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_code`, `team_name`, `description`, `owner_id`, `owner_name`, `enabled`, `sort`, `development_mode`, `enable_git_sync_check`) VALUES (7, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 'OMS-ORDER', '订单', '', 1, '超级管理员', b'1', 0, 'STANDARD', b'0');
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (25, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 5, '汤峰岷', '', NOW()); INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (25, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 5, '汤峰岷', '', NOW());
@ -734,6 +734,12 @@ INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `cre
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (37, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 3, 14, '宋伟', '', NOW()); INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (37, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 3, 14, '宋伟', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (38, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 4, 14, '宋伟', '', NOW()); INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (38, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 4, 14, '宋伟', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (39, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 15, '路宽', '', NOW()); INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (39, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 15, '路宽', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (40, 'dengqichen', NOW(), 'dengqichen', NOW(), 1, b'0', 7, 11, '邓骐辰', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (41, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 14, '宋伟', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (42, 'yangfan', NOW(), 'yangfan', NOW(), 1, b'0', 5, 16, '杨帆', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (43, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 3, 16, '杨帆', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (44, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 3, 10, '马也', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_member` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `user_id`, `user_name`, `role_in_team`, `join_time`) VALUES (45, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 3, 12, '王栋柱', '', NOW());
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (2, 'admin', NOW(), 'admin', NOW(), 1, b'0', 4, 2, 2, 'JENKINS', 2, 497, 'release/1.4.0', 4, 401, 'release/1.4.1', 3, 'ibp-uat-scp-longi-module', 1); INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (2, 'admin', NOW(), 'admin', NOW(), 1, b'0', 4, 2, 2, 'JENKINS', 2, 497, 'release/1.4.0', 4, 401, 'release/1.4.1', 3, 'ibp-uat-scp-longi-module', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (9, 'admin', NOW(), 'admin', NOW(), 1, b'0', 4, 1, 2, 'JENKINS', 4, 413, 'release/1.4.0', NULL, NULL, NULL, 3, 'ibp-uat-scp-meta', 1); INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (9, 'admin', NOW(), 'admin', NOW(), 1, b'0', 4, 1, 2, 'JENKINS', 4, 413, 'release/1.4.0', NULL, NULL, NULL, 3, 'ibp-uat-scp-meta', 1);
@ -799,12 +805,24 @@ INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`,
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (87, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 27, 5, 'NATIVE', 6, 37, 'release/1.0-localization', NULL, NULL, NULL, NULL, '', 2); INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (87, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 27, 5, 'NATIVE', 6, 37, 'release/1.0-localization', NULL, NULL, NULL, NULL, '', 2);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (88, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 28, 5, 'NATIVE', 6, 41, 'release/1.0-localization', NULL, NULL, NULL, NULL, '', 2); INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (88, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 28, 5, 'NATIVE', 6, 41, 'release/1.0-localization', NULL, NULL, NULL, NULL, '', 2);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (89, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 29, 5, 'NATIVE', 6, 43, 'release/1.0-localization', NULL, NULL, NULL, NULL, '', 2); INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (89, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 29, 5, 'NATIVE', 6, 43, 'release/1.0-localization', NULL, NULL, NULL, NULL, '', 2);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (90, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 34, 8, 'JENKINS', 2, 694, 'main', NULL, NULL, NULL, 1, 'test-lianyu-oms-web', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (91, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 33, 8, 'JENKINS', 2, 688, 'main', NULL, NULL, NULL, 1, 'test-lianyu-oms-main', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (92, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 32, 8, 'JENKINS', 2, 703, 'main', NULL, NULL, NULL, 1, 'test-lianyu-oms-job', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (93, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 31, 8, 'JENKINS', 2, 691, 'main', NULL, NULL, NULL, 1, 'test-lianyu-oms-gateway', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (94, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 30, 8, 'JENKINS', 2, 704, 'main', NULL, NULL, NULL, 1, 'test-lianyu-oms-admin', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (95, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 34, 9, 'JENKINS', 2, 694, 'prod', NULL, NULL, NULL, 1, 'prod-lianyu-oms-web', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (96, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 33, 9, 'JENKINS', 2, 688, 'prod', NULL, NULL, NULL, 1, 'prod-lianyu-oms-main', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (97, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 32, 9, 'JENKINS', 2, 703, 'prod', NULL, NULL, NULL, 1, 'prod-lianyu-oms-job', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (98, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 31, 9, 'JENKINS', 2, 691, 'prod', NULL, NULL, NULL, 1, 'prod-lianyu-oms-gateway', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_application` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `application_id`, `environment_id`, `build_type`, `source_git_system_id`, `source_git_project_id`, `source_branch`, `target_git_system_id`, `target_git_project_id`, `target_branch`, `deploy_system_id`, `deploy_job`, `workflow_definition_id`) VALUES (99, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 30, 9, 'JENKINS', 2, 704, 'prod', NULL, NULL, NULL, 1, 'prod-lianyu-oms-admin', 1);
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (8, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 5, b'0', NULL, b'0', ''); INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (8, 'admin', NOW(), 'admin', NOW(), 1, b'0', 5, 5, b'0', NULL, b'0', '');
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (9, 'admin', NOW(), 'admin', NOW(), 1, b'0', 4, 1, b'0', NULL, b'0', ''); INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (9, 'admin', NOW(), 'admin', NOW(), 1, b'0', 4, 1, b'0', NULL, b'0', '');
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (10, 'admin', NOW(), 'admin', NOW(), 1, b'0', 4, 2, b'1', '[6]', b'0', ''); INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (10, 'admin', NOW(), 'admin', NOW(), 1, b'0', 4, 2, b'1', '[6]', b'0', '');
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (11, 'admin', NOW(), 'admin', NOW(), 1, b'0', 3, 6, b'0', NULL, b'0', ''); INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (11, 'admin', NOW(), 'admin', NOW(), 1, b'0', 3, 6, b'0', NULL, b'0', '');
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (12, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 3, 7, b'0', NULL, b'0', ''); INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (12, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 3, 7, b'0', NULL, b'0', '');
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (13, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 8, b'0', NULL, b'0', '');
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `approval_required`, `approver_user_ids`, `require_code_review`, `remark`) VALUES (14, 'songwei', NOW(), 'songwei', NOW(), 1, b'0', 7, 9, b'0', NULL, b'0', '');
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_notification_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `notification_channel_id`, `pre_approval_notification_enabled`, `pre_approval_notification_template_id`, `build_notification_enabled`, `build_notification_template_id`, `build_failure_file_enabled`) VALUES (7, 'admin', NOW(), 'admin', NOW(), 2, b'0', 5, 5, 3, b'0', NULL, b'1', 9, b'1'); INSERT INTO `deploy-ease-platform`.`deploy_team_environment_notification_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `notification_channel_id`, `pre_approval_notification_enabled`, `pre_approval_notification_template_id`, `build_notification_enabled`, `build_notification_template_id`, `build_failure_file_enabled`) VALUES (7, 'admin', NOW(), 'admin', NOW(), 2, b'0', 5, 5, 3, b'0', NULL, b'1', 9, b'1');
INSERT INTO `deploy-ease-platform`.`deploy_team_environment_notification_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `notification_channel_id`, `pre_approval_notification_enabled`, `pre_approval_notification_template_id`, `build_notification_enabled`, `build_notification_template_id`, `build_failure_file_enabled`) VALUES (8, 'admin', NOW(), 'admin', NOW(), 2, b'0', 4, 2, 4, b'0', NULL, b'1', 8, b'1'); INSERT INTO `deploy-ease-platform`.`deploy_team_environment_notification_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`, `team_id`, `environment_id`, `notification_channel_id`, `pre_approval_notification_enabled`, `pre_approval_notification_template_id`, `build_notification_enabled`, `build_notification_template_id`, `build_failure_file_enabled`) VALUES (8, 'admin', NOW(), 'admin', NOW(), 2, b'0', 4, 2, 4, b'0', NULL, b'1', 8, b'1');
@ -954,3 +972,8 @@ INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `cat
INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (5, 5, 1, '达梦themetis-engine', 'jdbc:dm://219.142.42.183:5256', 'Database', NULL, 1, 'SYSDBA', '@1sdgCq456', '[]', 0, 1, 1, 'yangfan', NOW(), 'yangfan', NOW(), 1, 0); INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (5, 5, 1, '达梦themetis-engine', 'jdbc:dm://219.142.42.183:5256', 'Database', NULL, 1, 'SYSDBA', '@1sdgCq456', '[]', 0, 1, 1, 'yangfan', NOW(), 'yangfan', NOW(), 1, 0);
INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (6, 5, 3, '国产化进度WBS', 'https://doc.weixin.qq.com/sheet/e3_ARcAGAYpAJ8CNtHugwtMzTvqgKswZ?scode=ACQANQdcAC0CDRJHwTARcAGAYpAJ8&version=5.0.2.6011&platform=win&tab=fv4785', 'File', NULL, 0, NULL, NULL, '[]', 0, 1, 1, 'dengqichen', NOW(), 'dengqichen', NOW(), 1, 0); INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (6, 5, 3, '国产化进度WBS', 'https://doc.weixin.qq.com/sheet/e3_ARcAGAYpAJ8CNtHugwtMzTvqgKswZ?scode=ACQANQdcAC0CDRJHwTARcAGAYpAJ8&version=5.0.2.6011&platform=win&tab=fv4785', 'File', NULL, 0, NULL, NULL, '[]', 0, 1, 1, 'dengqichen', NOW(), 'dengqichen', NOW(), 1, 0);
INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (7, 5, 3, '国产化部署总结文档', 'https://doc.weixin.qq.com/doc/w3_ARcAGAYpAJ8CNzqTtEQs9Rr2sYnlK?scode=ACQANQdcAC0wXVa7u2AS4AkwY4AN4', 'File', NULL, 0, NULL, NULL, '[]', 0, 1, 1, 'dengqichen', NOW(), 'dengqichen', NOW(), 1, 0);
INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (8, 5, 3, '国产化适配方案', 'https://doc.weixin.qq.com/doc/w3_AUsABga_AOoCNg0KFhdUUTtaUu4Z0?scode=ACQANQdcAC0zjucYWgAS4AkwY4AN4', 'File', NULL, 0, NULL, NULL, '[]', 0, 1, 1, 'dengqichen', NOW(), 'dengqichen', NOW(), 1, 0);
INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (9, 5, 3, '国产化代码适配前期方案', 'https://doc.weixin.qq.com/doc/w3_AUsABga_AOoCNAy1z1rosTy0tPszb?scode=ACQANQdcAC0nBASFygAS4AkwY4AN4', 'File', NULL, 0, NULL, NULL, '[]', 0, 1, 1, 'dengqichen', NOW(), 'dengqichen', NOW(), 1, 0);
INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (10, 5, 1, 'SY项目组总结SQL脚本', 'https://drive.weixin.qq.com/s?k=ACQANQdcAC0m7Sv1Km', 'Database', NULL, 0, NULL, NULL, '[]', 0, 1, 1, 'dengqichen', NOW(), 'dengqichen', NOW(), 1, 0);
INSERT INTO `deploy-ease-platform`.`deploy_team_bookmark` (`id`, `team_id`, `category_id`, `title`, `url`, `icon`, `description`, `need_auth`, `username`, `password`, `tags`, `sort`, `enabled`, `is_public`, `create_by`, `create_time`, `update_by`, `update_time`, `version`, `deleted`) VALUES (11, 5, 3, 'DM数据库11/20-12/12日-新增DDL', 'https://doc.weixin.qq.com/doc/w3_ARcAGAYpAJ8CN2EdWidCGQbO3eUUr?scode=ACQANQdcAC0K4fTUhVARcAGAYpAJ8', NULL, NULL, 0, NULL, NULL, '[]', 0, 1, 1, 'yangfan', NOW(), 'yangfan', NOW(), 1, 0);

View File

@ -1491,9 +1491,13 @@ CREATE TABLE deploy_k8s_deployment
namespace_id BIGINT NOT NULL COMMENT '命名空间ID', namespace_id BIGINT NOT NULL COMMENT '命名空间ID',
deployment_name VARCHAR(255) NOT NULL COMMENT 'Deployment名称', deployment_name VARCHAR(255) NOT NULL COMMENT 'Deployment名称',
replicas INT NULL COMMENT '期望副本数', -- K8s副本数字段完整映射K8s API
available_replicas INT NULL COMMENT '可用副本数', desired_replicas INT NULL COMMENT '期望副本数来自spec.replicas用户声明的目标副本数',
ready_replicas INT NULL COMMENT '就绪副本数', current_replicas INT NULL COMMENT '当前副本数来自status.replicas所有Pod总数包括Running/Pending/Failed等所有状态',
available_replicas INT NULL COMMENT '可用副本数来自status.availableReplicasReady且可接收流量的Pod数',
ready_replicas INT NULL COMMENT '就绪副本数来自status.readyReplicas健康检查通过的Pod数',
updated_replicas INT NULL COMMENT '已更新副本数来自status.updatedReplicas已更新到最新版本的Pod数',
unavailable_replicas INT NULL COMMENT '不可用副本数来自status.unavailableReplicas不可用的Pod数',
total_restart_count INT NULL COMMENT '总重启次数所有Pod的重启次数总和', total_restart_count INT NULL COMMENT '总重启次数所有Pod的重启次数总和',
image VARCHAR(500) NULL COMMENT '容器镜像', image VARCHAR(500) NULL COMMENT '容器镜像',

View File

@ -40,7 +40,7 @@ export const PodRow: React.FC<PodRowProps> = ({ pod, deploymentId, onViewLogs })
}; };
// 获取主容器信息 // 获取主容器信息
const mainContainer = pod.containers[0]; const mainContainer = pod.containers?.[0];
// 复制镜像名称 // 复制镜像名称
const handleCopyImage = () => { const handleCopyImage = () => {