Skip to content

Commit

Permalink
use directory where app user has rw access
Browse files Browse the repository at this point in the history
  • Loading branch information
lldelisle committed Oct 13, 2023
1 parent ce82be8 commit 822f4c5
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions tools/interactive/interactivetool_ilastik.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,12 @@
exit 1 &&
#end if
export HOME=\$PWD &&
## Create a directory where the app user has access
mkdir -p ./output &&
chown 1000:1000 ./output/ &&
## Make a copy of the existing project if exists
#if str($input_type.existing) == "existing":
cp '$input_type.project' ./MyProject.ilp &&
cp '$input_type.project' ./output/MyProject.ilp &&
#end if
## Link input images to current working directory
Expand All @@ -36,9 +39,9 @@
#end for
## Write the bash script to run:
#if str($input_type.existing) == "new":
echo "ilastik --new_project \$HOME/MyProject.ilp --workflow '$input_type.Workflow'" > ./ilastik_with_args &&
echo "ilastik --new_project \$HOME/output/MyProject.ilp --workflow '$input_type.Workflow'" > ./ilastik_with_args &&
#else:
echo "ilastik --project \$HOME/MyProject.ilp" > ./ilastik_with_args &&
echo "ilastik --project \$HOME/output/MyProject.ilp" > ./ilastik_with_args &&
#end if
## Copy it to /bin/ so it will be used by the container:
chmod +x ./ilastik_with_args &&
Expand Down Expand Up @@ -80,7 +83,7 @@
</inputs>

<outputs>
<data name="ilastik_project" format="h5" label="Ilastik project file" from_work_dir="MyProject.ilp"/>
<data name="ilastik_project" format="h5" label="Ilastik project file" from_work_dir="output/MyProject.ilp"/>
</outputs>

<tests>
Expand Down

0 comments on commit 822f4c5

Please sign in to comment.