package com.qqchen.deploy.backend.deploy.dto;

import com.fasterxml.jackson.databind.JsonNode;
import com.qqchen.deploy.backend.deploy.enums.BuildTypeEnum;
import com.qqchen.deploy.backend.deploy.enums.DeployTypeEnum;
import com.qqchen.deploy.backend.framework.dto.BaseDTO;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 环境DTO
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Schema(description = "环境DTO")
public class EnvironmentDTO extends BaseDTO {

    @Schema(description = "租户编码")
    private String tenantCode;

    @Schema(description = "环境编码")
    @NotBlank(message = "环境编码不能为空")
    private String envCode;

    @Schema(description = "环境名称")
    @NotBlank(message = "环境名称不能为空")
    private String envName;

    @Schema(description = "环境描述")
    private String envDesc;

    @Schema(description = "构建方式：JENKINS-Jenkins构建, GITLAB_RUNNER-GitLab Runner构建, GITHUB_ACTION-GitHub Action构建")
    private BuildTypeEnum buildType;

    @Schema(description = "部署方式：K8S-Kubernetes集群部署, DOCKER-Docker容器部署, VM-虚拟机部署")
    private DeployTypeEnum deployType;

    @NotNull(message = "启用字段不能为空")
    private Boolean enabled;

    @Schema(description = "排序号")
    @NotNull(message = "排序号不能为空")
    private Integer sort;
} 