export interface CustomVariable { name: string value: string } export interface SshConfig { host: string port?: number username: string password: string } export type TerminalType = 'CMD' | 'POWERSHELL' | 'GIT_BASH' | 'SSH' export type RunStatus = 'STOPPED' | 'RUNNING' | 'STARTING' | 'STOPPING' | 'ERROR' export interface ServiceConfig { id?: string name: string description?: string startupCommand: string workDir?: string terminalType: TerminalType sshConfig?: SshConfig variables?: CustomVariable[] webUrl?: string logEncoding?: string createdAt?: string updatedAt?: string status?: RunStatus pid?: number | null statusMessage?: string | null lastStartedAt?: string | null lastStoppedAt?: string | null } /** 占用端口的进程信息 */ export interface OccupiedProcess { pid: number processName: string commandLine: string } /** 端口检查结果 */ export interface PortCheckResult { variableName: string port: number occupied: boolean processes: OccupiedProcess[] } /** 杀死进程结果 */ export interface KillResult { success: boolean message: string }