-
Notifications
You must be signed in to change notification settings - Fork 357
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
Showing
7 changed files
with
184 additions
and
16 deletions.
There are no files selected for viewing
15 changes: 1 addition & 14 deletions
15
centaur/src/main/resources/standardTestCases/custom_mount_point.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
...r/src/main/resources/standardTestCases/custom_mount_point/gcpbatch_custom_mount_point.wdl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# 1) Mounting a SSD to a custom location and default location with custom disk size | ||
# 2) Write a file to that mount | ||
# 3) Changing directory within a command shouldn't break Cromwell | ||
# 4) Use the file that was written on the mount as an output | ||
# ChrisTM | ||
task t { | ||
String v | ||
|
||
command { | ||
echo "bazqux" > some_file | ||
|
||
cd /mnt/disks/some | ||
echo "foobar" > some_file | ||
} | ||
|
||
output { | ||
String out1 = read_string("some_file") | ||
String out2 = read_string("/mnt/disks/some/some_file") | ||
} | ||
|
||
runtime { | ||
docker: "ubuntu:" + v | ||
disks: "local-disk 20 SSD, /mnt/disks/some 20 SSD" | ||
} | ||
} | ||
|
||
workflow custom_mount_point { | ||
call t {input: v="latest"} | ||
|
||
output { | ||
String o1 = t.out1 | ||
String o2 = t.out2 | ||
} | ||
} |
3 changes: 1 addition & 2 deletions
3
centaur/src/main/resources/standardTestCases/draft3_custom_mount_point.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
centaur/src/main/resources/standardTestCases/gcpbatch_custom_mount_point.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: gcpbatch_custom_mount_point | ||
testFormat: workflowsuccess | ||
|
||
backends: [GCPBATCH] | ||
|
||
files { | ||
workflow: custom_mount_point/gcpbatch_custom_mount_point.wdl | ||
# https://github.com/broadinstitute/cromwell/issues/3998 | ||
options: custom_mount_point/custom_mount_point.options | ||
} | ||
|
||
metadata { | ||
"calls.custom_mount_point.t.backend": "GCPBATCH" | ||
"calls.custom_mount_point.t.backendStatus": "Success" | ||
|
||
"outputs.custom_mount_point.o1": "bazqux" | ||
"outputs.custom_mount_point.o2": "foobar" | ||
} |
25 changes: 25 additions & 0 deletions
25
centaur/src/main/resources/standardTestCases/gcpbatch_draft3_custom_mount_point.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: gcpbatch_draft3_custom_mount_point | ||
testFormat: workflowsuccess | ||
backends: [GCPBATCH] | ||
|
||
files { | ||
workflow: wdl_draft3/custom_mount_point/gcpbatch_custom_mount_point.wdl | ||
# https://github.com/broadinstitute/cromwell/issues/3998 | ||
options: wdl_draft3/custom_mount_point/custom_mount_point.options | ||
} | ||
|
||
metadata { | ||
"calls.custom_mount_point.local_and_custom.backend": "GCPBATCH" | ||
"calls.custom_mount_point.local_and_custom.backendStatus": "Success" | ||
|
||
"calls.custom_mount_point.local_only.backend": "GCPBATCH" | ||
"calls.custom_mount_point.local_only.backendStatus": "Success" | ||
|
||
"calls.custom_mount_point.custom_only.backend": "GCPBATCH" | ||
"calls.custom_mount_point.custom_only.backendStatus": "Success" | ||
|
||
"outputs.custom_mount_point.o1": "local disk contents" | ||
"outputs.custom_mount_point.o2": "custom mount contents" | ||
"outputs.custom_mount_point.o3": "local disk contents" | ||
"outputs.custom_mount_point.o4": "custom mount contents" | ||
} |
92 changes: 92 additions & 0 deletions
92
...resources/standardTestCases/wdl_draft3/custom_mount_point/gcpbatch_custom_mount_point.wdl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
version 1.0 | ||
|
||
task local_and_custom { | ||
input { | ||
String v | ||
} | ||
|
||
|
||
output { | ||
String out1 = read_string("some_file") | ||
String out2 = read_string("/mnt/disks/some/some_file") | ||
} | ||
command <<< | ||
|
||
echo "local disk contents" > some_file | ||
|
||
cd /mnt/disks/some | ||
echo "custom mount contents" > some_file | ||
|
||
>>> | ||
runtime { | ||
docker: "ubuntu:" + v | ||
disks: "local-disk 20 SSD, /mnt/disks/some 20 SSD" | ||
} | ||
|
||
} | ||
|
||
task local_only { | ||
|
||
input { | ||
String v | ||
} | ||
|
||
command { | ||
echo "local disk contents" > some_file | ||
} | ||
|
||
runtime { | ||
docker: "ubuntu:" + v | ||
disks: "local-disk 20 SSD" | ||
} | ||
|
||
output { | ||
String out = read_string("some_file") | ||
} | ||
} | ||
|
||
task custom_only { | ||
|
||
input { | ||
String v | ||
} | ||
|
||
command { | ||
cd /mnt/disks/some | ||
echo "custom mount contents" > some_file | ||
} | ||
|
||
runtime { | ||
docker: "ubuntu:" + v | ||
disks: "/mnt/disks/some 20 SSD" | ||
} | ||
|
||
output { | ||
String out = read_string("/mnt/disks/some/some_file") | ||
} | ||
} | ||
|
||
workflow custom_mount_point { | ||
|
||
call local_and_custom { | ||
input: | ||
v = "latest" | ||
} | ||
|
||
call local_only { | ||
input: | ||
v = "latest" | ||
} | ||
|
||
call custom_only { | ||
input: | ||
v = "latest" | ||
} | ||
|
||
output { | ||
String o1 = local_and_custom.out1 | ||
String o2 = local_and_custom.out2 | ||
String o3 = local_only.out | ||
String o4 = custom_only.out | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters