X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/02fe86a56f080ed1d5770ad6c6856a15f50ab508..da5e144c103d5abb2bca727f40a14e5da052264e:/src/views/run-process-panel/run-process-advanced-form.tsx

diff --git a/src/views/run-process-panel/run-process-advanced-form.tsx b/src/views/run-process-panel/run-process-advanced-form.tsx
index 0400b850..52abfe80 100644
--- a/src/views/run-process-panel/run-process-advanced-form.tsx
+++ b/src/views/run-process-panel/run-process-advanced-form.tsx
@@ -2,16 +2,15 @@
 //
 // SPDX-License-Identifier: AGPL-3.0
 
-import * as React from 'react';
+import React from 'react';
 import { ExpansionPanel, ExpansionPanelDetails, ExpansionPanelSummary } from '@material-ui/core';
 import { reduxForm, Field } from 'redux-form';
 import { Grid } from '@material-ui/core';
-import { TextField } from '~/components/text-field/text-field';
-import { ExpandIcon } from '~/components/icon/icon';
+import { TextField } from 'components/text-field/text-field';
+import { ExpandIcon } from 'components/icon/icon';
 import * as IntInput from './inputs/int-input';
-import { min } from '~/validators/min';
-import { optional } from '~/validators/optional';
-import { SwitchField } from '~/components/switch-field/switch-field';
+import { min } from 'validators/min';
+import { optional } from 'validators/optional';
 
 export const RUN_PROCESS_ADVANCED_FORM = 'runProcessAdvancedForm';
 
@@ -20,15 +19,15 @@ export const RUNTIME_FIELD = 'runtime';
 export const RAM_FIELD = 'ram';
 export const VCPUS_FIELD = 'vcpus';
 export const KEEP_CACHE_RAM_FIELD = 'keep_cache_ram';
-export const API_FIELD = 'api';
+export const RUNNER_IMAGE_FIELD = 'acr_container_image';
 
 export interface RunProcessAdvancedFormData {
     [OUTPUT_FIELD]?: string;
     [RUNTIME_FIELD]?: number;
     [RAM_FIELD]: number;
     [VCPUS_FIELD]: number;
-    [KEEP_CACHE_RAM_FIELD]?: number;
-    [API_FIELD]?: boolean;
+    [KEEP_CACHE_RAM_FIELD]: number;
+    [RUNNER_IMAGE_FIELD]: string;
 }
 
 export const RunProcessAdvancedForm =
@@ -45,13 +44,13 @@ export const RunProcessAdvancedForm =
                         <Grid item xs={12} md={6}>
                             <Field
                                 name={OUTPUT_FIELD}
-                                component={TextField}
+                                component={TextField as any}
                                 label="Output name" />
                         </Grid>
                         <Grid item xs={12} md={6}>
                             <Field
                                 name={RUNTIME_FIELD}
-                                component={TextField}
+                                component={TextField as any}
                                 helperText="Maximum running time (in seconds) that this container will be allowed to run before being cancelled."
                                 label="Runtime limit"
                                 parse={IntInput.parse}
@@ -62,7 +61,7 @@ export const RunProcessAdvancedForm =
                         <Grid item xs={12} md={6}>
                             <Field
                                 name={RAM_FIELD}
-                                component={TextField}
+                                component={TextField as any}
                                 label="RAM"
                                 helperText="Number of ram bytes to be used to run this process."
                                 parse={IntInput.parse}
@@ -74,7 +73,7 @@ export const RunProcessAdvancedForm =
                         <Grid item xs={12} md={6}>
                             <Field
                                 name={VCPUS_FIELD}
-                                component={TextField}
+                                component={TextField as any}
                                 label="VCPUs"
                                 helperText="Number of cores to be used to run this process."
                                 parse={IntInput.parse}
@@ -86,7 +85,7 @@ export const RunProcessAdvancedForm =
                         <Grid item xs={12} md={6}>
                             <Field
                                 name={KEEP_CACHE_RAM_FIELD}
-                                component={TextField}
+                                component={TextField as any}
                                 label="Keep cache RAM"
                                 helperText="Number of keep cache bytes to be used to run this process."
                                 parse={IntInput.parse}
@@ -96,13 +95,11 @@ export const RunProcessAdvancedForm =
                         </Grid>
                         <Grid item xs={12} md={6}>
                             <Field
-                                name={API_FIELD}
-                                component={SwitchField}
-                                switchProps={{
-                                    color: 'primary'
-                                }}
-                                label='API'
-                                helperText='When set, ARVADOS_API_HOST and ARVADOS_API_TOKEN will be set, and process will have networking enabled to access the Arvados API server.' />
+                                name={RUNNER_IMAGE_FIELD}
+                                component={TextField as any}
+                                label='Runner'
+                                required
+                                helperText='The container image with arvados-cwl-runner that will execute this workflow.' />
                         </Grid>
                     </Grid>
                 </ExpansionPanelDetails>
