27 lines
715 B
TypeScript
27 lines
715 B
TypeScript
// src/interfaces/workspace.ts
|
|
// Copyright (C) 2026 Rob Colbert <rob.colbert@openplatform.us>
|
|
// Licensed under the Apache License, Version 2.0
|
|
|
|
import type { IUser } from "./user.js";
|
|
import { GadgetId } from "../lib/gadget-id.ts";
|
|
import { HydratedDocument } from "mongoose";
|
|
import { IDroneRegistration } from "./drone-registration.ts";
|
|
|
|
export enum WorkspaceStatus {
|
|
Active = "online",
|
|
Inactive = "offline",
|
|
Archived = "archived",
|
|
}
|
|
|
|
export interface IWorkspace {
|
|
_id: GadgetId;
|
|
createdAt: Date;
|
|
user: IUser | GadgetId;
|
|
status: WorkspaceStatus;
|
|
hostname: string;
|
|
rootDir: string;
|
|
lockedDrone?: GadgetId | IDroneRegistration;
|
|
}
|
|
|
|
export type WorkspaceDocument = HydratedDocument<IWorkspace>;
|