1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: AGPL-3.0
5 import { Resource, ResourceKind, ResourceWithProperties } from './resource';
6 import { MountType } from 'models/mount-types';
7 import { RuntimeConstraints } from './runtime-constraints';
8 import { SchedulingParameters } from './scheduling-parameters';
10 export enum ContainerRequestState {
11 UNCOMMITTED = 'Uncommitted',
12 COMMITTED = 'Committed',
16 export interface ContainerRequestResource
17 extends Resource, ResourceWithProperties {
19 containerCountMax: number;
20 containerCount: number;
21 containerImage: string;
22 containerUuid: string | null;
23 cumulativeCost: number;
29 kind: ResourceKind.CONTAINER_REQUEST;
30 logUuid: string | null;
31 mounts: { [path: string]: MountType };
35 outputProperties: any;
36 outputStorageClasses: string[];
38 outputUuid: string | null;
40 priority: number | null;
41 requestingContainerUuid: string | null;
42 runtimeConstraints: RuntimeConstraints;
43 schedulingParameters: SchedulingParameters;
44 state: ContainerRequestState;
48 // Until the api supports unselecting fields, we need a list of all other fields to omit mounts
49 export const containerRequestFieldsNoMounts = [
51 "container_count_max",
67 "modified_by_client_uuid",
68 "modified_by_user_uuid",
73 "output_storage_classes",
80 "requesting_container_uuid",
81 "runtime_constraints",
82 "scheduling_parameters",