init
This commit is contained in:
@@ -0,0 +1,94 @@
|
||||
export interface User {
|
||||
id: string;
|
||||
email: string;
|
||||
firstName: string;
|
||||
lastName: string;
|
||||
role: 'user' | 'admin';
|
||||
isActive: boolean;
|
||||
namespace?: string;
|
||||
createdAt: string;
|
||||
}
|
||||
|
||||
export interface Application {
|
||||
id: string;
|
||||
name: string;
|
||||
description?: string;
|
||||
runtime: 'nodejs' | 'laravel';
|
||||
databaseType: 'mysql' | 'postgresql' | 'none';
|
||||
gitUrl?: string;
|
||||
codePath?: string;
|
||||
envVars?: Record<string, string>;
|
||||
cpuRequest: string;
|
||||
cpuLimit: string;
|
||||
memoryRequest: string;
|
||||
memoryLimit: string;
|
||||
replicas: number;
|
||||
port: number;
|
||||
userId: string;
|
||||
clusterId?: string;
|
||||
latestImageTag?: string;
|
||||
subdomain?: string;
|
||||
deployments?: Deployment[];
|
||||
createdAt: string;
|
||||
updatedAt: string;
|
||||
}
|
||||
|
||||
export interface Deployment {
|
||||
id: string;
|
||||
status: DeploymentStatus;
|
||||
imageTag: string;
|
||||
version?: string;
|
||||
buildLog?: string;
|
||||
deployLog?: string;
|
||||
errorMessage?: string;
|
||||
applicationId: string;
|
||||
triggeredBy: string;
|
||||
createdAt: string;
|
||||
finishedAt?: string;
|
||||
}
|
||||
|
||||
export type DeploymentStatus =
|
||||
| 'pending'
|
||||
| 'building'
|
||||
| 'build_failed'
|
||||
| 'deploying'
|
||||
| 'running'
|
||||
| 'failed'
|
||||
| 'stopped'
|
||||
| 'deleting';
|
||||
|
||||
export interface Cluster {
|
||||
id: string;
|
||||
name: string;
|
||||
description?: string;
|
||||
status: 'active' | 'inactive' | 'maintenance';
|
||||
apiServer: string;
|
||||
region?: string;
|
||||
provider?: string;
|
||||
isDefault: boolean;
|
||||
defaultCpuLimit: string;
|
||||
defaultMemoryLimit: string;
|
||||
maxAppsPerUser: number;
|
||||
createdAt: string;
|
||||
}
|
||||
|
||||
export interface AuthResponse {
|
||||
user: User;
|
||||
accessToken: string;
|
||||
refreshToken: string;
|
||||
}
|
||||
|
||||
export interface CreateApplicationDto {
|
||||
name: string;
|
||||
description?: string;
|
||||
runtime: 'nodejs' | 'laravel';
|
||||
databaseType: 'mysql' | 'postgresql' | 'none';
|
||||
gitUrl?: string;
|
||||
envVars?: Record<string, string>;
|
||||
cpuRequest?: string;
|
||||
cpuLimit?: string;
|
||||
memoryRequest?: string;
|
||||
memoryLimit?: string;
|
||||
replicas?: number;
|
||||
port?: number;
|
||||
}
|
||||
Reference in New Issue
Block a user