|
19 | 19 |
|
20 | 20 | Use a JSON object in a separate file to describe the input of a run:
|
21 | 21 |
|
22 |
| - *echo-job.json* |
| 22 | + *echo-job.yml* |
23 | 23 | ```
|
24 |
| - - $include: examples/echo-job.json |
| 24 | + - $include: examples/echo-job.yml |
25 | 25 | - |
|
26 | 26 | ```
|
27 | 27 |
|
28 | 28 | Now invoke `cwl-runner` with the tool wrapper and the input object on the
|
29 | 29 | command line:
|
30 | 30 |
|
31 | 31 | ```
|
32 |
| - $ cwl-runner example-echo.cwl example-echo-job.json |
| 32 | + $ cwl-runner 1st.cwl echo-job.yml |
33 | 33 | [job 140199012414352] $ echo 'Hello world!'
|
34 | 34 | Hello world!
|
35 | 35 | Final process status is success
|
|
94 | 94 | - |
|
95 | 95 | ```
|
96 | 96 |
|
97 |
| - *inp-job.json* |
| 97 | + *inp-job.yml* |
98 | 98 | ```
|
99 |
| - - $include: examples/inp-job.json |
| 99 | + - $include: examples/inp-job.yml |
100 | 100 | - |
|
101 | 101 | ```
|
102 | 102 |
|
|
107 | 107 | command line:
|
108 | 108 |
|
109 | 109 | ```
|
110 |
| - $ cwl-runner example-inp.cwl example-inp-job.json |
| 110 | + $ cwl-runner inp.cwl inp-job.yml |
111 | 111 | [job 140020149614160] /home/example$ echo -f -i42 --example-string hello --file=/home/example/whale.txt
|
112 | 112 | -f -i42 --example-string hello --file=/home/example/whale.txt
|
113 | 113 | Final process status is success
|
|
209 | 209 | - |
|
210 | 210 | ```
|
211 | 211 |
|
212 |
| - *tar-job.json* |
| 212 | + *tar-job.yml* |
213 | 213 | ```
|
214 |
| - - $include: examples/tar-job.json |
| 214 | + - $include: examples/tar-job.yml |
215 | 215 | - |
|
216 | 216 | ```
|
217 | 217 |
|
218 | 218 | Invoke `cwl-runner` with the tool wrapper and the input object on the
|
219 | 219 | command line:
|
220 | 220 | ```
|
221 |
| - $ cwl-runner example-tar.cwl example-tar-job.json |
| 221 | + $ cwl-runner tar.cwl tar-job.yml |
222 | 222 | [job 139868145165200] $ tar xf /home/example/hello.tar
|
223 | 223 | Final process status is success
|
224 | 224 | {
|
|
259 | 259 | - |
|
260 | 260 | ```
|
261 | 261 |
|
262 |
| - *echo-job.json* |
| 262 | + *echo-job.yml* |
263 | 263 | ```
|
264 |
| - - $include: examples/echo-job.json |
| 264 | + - $include: examples/echo-job.yml |
265 | 265 | - |
|
266 | 266 | ```
|
267 | 267 |
|
268 | 268 | Now invoke `cwl-runner` providing the tool wrapper and the input object
|
269 | 269 | on the command line:
|
270 | 270 |
|
271 | 271 | ```
|
272 |
| - $ cwl-runner example-stdout.cwl example-echo-job.json |
| 272 | + $ cwl-runner stdout.cwl echo-job.yml |
273 | 273 | [job 140199012414352] $ echo 'Hello world!' > output.txt
|
274 | 274 | Final process status is success
|
275 | 275 | {
|
|
299 | 299 | - |
|
300 | 300 | ```
|
301 | 301 |
|
302 |
| - *tar-param-job.json* |
| 302 | + *tar-param-job.yml* |
303 | 303 | ```
|
304 |
| - - $include: examples/tar-param-job.json |
| 304 | + - $include: examples/tar-param-job.yml |
305 | 305 | - |
|
306 | 306 | ```
|
307 | 307 |
|
308 | 308 | Invoke `cwl-runner` with the tool wrapper and the input object on the
|
309 | 309 | command line:
|
310 | 310 | ```
|
311 |
| - $ cwl-runner example-tar-param.cwl example-tar-param-job.json |
| 311 | + $ cwl-runner example-tar-param.cwl example-tar-param-job.yml |
312 | 312 | [job 139868145165200] $ tar xf /home/example/hello.tar goodbye.txt
|
313 | 313 | Final process status is success
|
314 | 314 | {
|
|
365 | 365 | - |
|
366 | 366 | ```
|
367 | 367 |
|
368 |
| - *docker-job.json* |
| 368 | + *docker-job.yml* |
369 | 369 | ```
|
370 |
| - - $include: examples/docker-job.json |
| 370 | + - $include: examples/docker-job.yml |
371 | 371 | - |
|
372 | 372 | ```
|
373 | 373 |
|
374 | 374 | Now invoke `cwl-runner` providing the tool wrapper and the input object
|
375 | 375 | on the command line:
|
376 | 376 |
|
377 | 377 | ```
|
378 |
| - $ cwl-runner example-docker.cwl example-docker-job.json |
| 378 | + $ cwl-runner example-docker.cwl example-docker-job.yml |
379 | 379 | [job 140259721854416] /home/example$ docker run -i --volume=/home/example/hello.js:/var/lib/cwl/job369354770_examples/hello.js:ro --volume=/home/example:/var/spool/cwl:rw --volume=/tmp/tmpDLs5hm:/tmp:rw --workdir=/var/spool/cwl --read-only=true --net=none --user=1001 --rm --env=TMPDIR=/tmp node:slim node /var/lib/cwl/job369354770_examples/hello.js
|
380 | 380 | Hello world!
|
381 | 381 | Final process status is success
|
|
408 | 408 | - |
|
409 | 409 | ```
|
410 | 410 |
|
411 |
| - *arguments-job.json* |
| 411 | + *arguments-job.yml* |
412 | 412 | ```
|
413 |
| - - $include: examples/arguments-job.json |
| 413 | + - $include: examples/arguments-job.yml |
414 | 414 | - |
|
415 | 415 | ```
|
416 | 416 |
|
417 | 417 | Now invoke `cwl-runner` providing the tool wrapper and the input object
|
418 | 418 | on the command line:
|
419 | 419 |
|
420 | 420 | ```
|
421 |
| - $ cwl-runner example-arguments.cwl example-arguments-job.json |
| 421 | + $ cwl-runner example-arguments.cwl example-arguments-job.yml |
422 | 422 | [job 140051188854928] /home/example$ docker run -i --volume=/home/example/Hello.java:/var/lib/cwl/job710906416_example/Hello.java:ro --volume=/home/example:/var/spool/cwl:rw --volume=/tmp/tmpdlQDWi:/tmp:rw --workdir=/var/spool/cwl --read-only=true --net=none --user=1001 --rm --env=TMPDIR=/tmp java:7 javac -d /var/spool/cwl /var/lib/cwl/job710906416_examples/Hello.java
|
423 | 423 | Final process status is success
|
424 | 424 | {
|
|
458 | 458 | under the `type` field with `type: array` and `items` defining the valid
|
459 | 459 | data types that may appear in the array.
|
460 | 460 |
|
461 |
| - *array.cwl* |
| 461 | + *array-inputs.cwl* |
462 | 462 | ```
|
463 |
| - - $include: examples/array.cwl |
| 463 | + - $include: examples/array-inputs.cwl |
464 | 464 | - |
|
465 | 465 | ```
|
466 | 466 |
|
467 |
| - *array-job.json* |
| 467 | + *array-inputs-job.yml* |
468 | 468 | ```
|
469 |
| - - $include: examples/array-job.json |
| 469 | + - $include: examples/array-inputs-job.yml |
470 | 470 | - |
|
471 | 471 | ```
|
472 | 472 |
|
473 | 473 | Now invoke `cwl-runner` providing the tool wrapper and the input object
|
474 | 474 | on the command line:
|
475 | 475 |
|
476 | 476 | ```
|
477 |
| - $ cwl-runner example-array.cwl example-array-job.json |
| 477 | + $ cwl-runner array-inputs.cwl array-inputs-job.yml |
478 | 478 | /home/peter/work/cwl-venv/bin/cwltool 1.0.20160325210917
|
479 | 479 | [job 140334923640912] /home/peter/work/common-workflow-language/draft-3/examples$ echo -A one two three -B=four -B=five -B=six -C=seven,eight,nine
|
480 | 480 | -A one two three -B=four -B=five -B=six -C=seven,eight,nine
|
|
506 | 506 | - |
|
507 | 507 | ```
|
508 | 508 |
|
509 |
| - *record-job1.json* |
| 509 | + *record-job1.yml* |
510 | 510 | ```
|
511 |
| - - $include: examples/record-job1.json |
| 511 | + - $include: examples/record-job1.yml |
512 | 512 | - |
|
513 | 513 | ```
|
514 | 514 |
|
515 | 515 | ```
|
516 |
| - $ cwl-runner example-record.cwl example-record-job1.json |
| 516 | + $ cwl-runner record.cwl record-job1.yml |
517 | 517 | Workflow error:
|
518 | 518 | Error validating input record, could not validate field `dependent_parameters` because
|
519 | 519 | missing required field `itemB`
|
520 | 520 | ```
|
521 | 521 |
|
522 | 522 | In the first example, you can't provide `itemA` without also providing `itemB`.
|
523 | 523 |
|
524 |
| - *record-job2.json* |
| 524 | + *record-job2.yml* |
525 | 525 | ```
|
526 |
| - - $include: examples/record-job2.json |
| 526 | + - $include: examples/record-job2.yml |
527 | 527 | - |
|
528 | 528 | ```
|
529 | 529 |
|
530 | 530 | ```
|
531 |
| - $ cwl-runner example-record.cwl example-record-job2.json |
| 531 | + $ cwl-runner record.cwl record-job2.yml |
532 | 532 | [job 140566927111376] /home/example$ echo -A one -B two -C three
|
533 | 533 | -A one -B two -C three
|
534 | 534 | Final process status is success
|
|
538 | 538 | In the second example, `itemC` and `itemD` are exclusive, so only `itemC`
|
539 | 539 | is added to the command line and `itemD` is ignored.
|
540 | 540 |
|
541 |
| - *record-job3.json* |
| 541 | + *record-job3.yml* |
542 | 542 | ```
|
543 |
| - - $include: examples/record-job2.json |
| 543 | + - $include: examples/record-job2.yml |
544 | 544 | - |
|
545 | 545 | ```
|
546 | 546 |
|
547 | 547 | ```
|
548 |
| - $ cwl-runner example-record.cwl example-record-job3.json |
| 548 | + $ cwl-runner record.cwl record-job3.yml |
549 | 549 | [job 140606932172880] /home/example$ echo -A one -B two -D four
|
550 | 550 | -A one -B two -D four
|
551 | 551 | Final process status is success
|
|
568 | 568 | - |
|
569 | 569 | ```
|
570 | 570 |
|
571 |
| - *echo-job.json* |
| 571 | + *echo-job.yml* |
572 | 572 | ```
|
573 |
| - - $include: examples/echo-job.json |
| 573 | + - $include: examples/echo-job.yml |
574 | 574 | - |
|
575 | 575 | ```
|
576 | 576 |
|
577 | 577 | Now invoke `cwl-runner` with the tool wrapper and the input object on the
|
578 | 578 | command line:
|
579 | 579 |
|
580 | 580 | ```
|
581 |
| - $ cwltool example-env.cwl example-echo-job.json |
| 581 | + $ cwl-runner env.cwl echo-job.yml |
582 | 582 | [job 140710387785808] /home/example$ env
|
583 | 583 | PATH=/bin:/usr/bin:/usr/local/bin
|
584 | 584 | HELLO=Hello world!
|
|
602 | 602 | ```
|
603 | 603 |
|
604 | 604 | ```
|
605 |
| - $ cwl-runner example-expression.cwl empty.json |
| 605 | + $ cwl-runner expression.cwl empty.yml |
606 | 606 | [job 140000594593168] /home/example$ echo -A 2 -B baz -C 10 9 8 7 6 5 4 3 2 1
|
607 | 607 | -A 2 -B baz -C 10 9 8 7 6 5 4 3 2 1
|
608 | 608 | Final process status is success
|
|
628 | 628 | - |
|
629 | 629 | ```
|
630 | 630 |
|
631 |
| - *echo-job.json* |
| 631 | + *echo-job.yml* |
632 | 632 | ```
|
633 |
| - - $include: examples/echo-job.json |
| 633 | + - $include: examples/echo-job.yml |
634 | 634 | - |
|
635 | 635 | ```
|
636 | 636 |
|
637 | 637 | Now invoke `cwl-runner` with the tool wrapper and the input object on the
|
638 | 638 | command line:
|
639 | 639 |
|
640 | 640 | ```
|
641 |
| - $ cwltool example-createfile.cwl example-echo-job.json |
| 641 | + $ cwltool createfile.cwl echo-job.yml |
642 | 642 | [job 140528604979344] /home/example$ cat example.conf
|
643 | 643 | CONFIGVAR=Hello world!
|
644 | 644 | Final process status is success
|
|
661 | 661 | - |
|
662 | 662 | ```
|
663 | 663 |
|
664 |
| - *arguments-job.json* |
| 664 | + *arguments-job.yml* |
665 | 665 | ```
|
666 |
| - - $include: examples/arguments-job.json |
| 666 | + - $include: examples/arguments-job.yml |
667 | 667 | - |
|
668 | 668 | ```
|
669 | 669 |
|
670 | 670 | Now invoke `cwl-runner` with the tool wrapper and the input object on the
|
671 | 671 | command line:
|
672 | 672 |
|
673 | 673 | ```
|
674 |
| - $ cwl-runner example-linkfile.cwl example-arguments-job.json |
| 674 | + $ cwl-runner linkfile.cwl arguments-job.yml |
675 | 675 | [job 139928309171664] /home/example$ docker run -i --volume=/home/peter/work/common-workflow-language/draft-3/examples/Hello.java:/var/lib/cwl/job557617295_examples/Hello.java:ro --volume=/home/peter/work/common-workflow-language/draft-3/examples:/var/spool/cwl:rw --volume=/tmp/tmpmNbApw:/tmp:rw --workdir=/var/spool/cwl --read-only=true --net=none --user=1001 --rm --env=TMPDIR=/tmp java:7 javac Hello.java
|
676 | 676 | Final process status is success
|
677 | 677 | {
|
|
0 commit comments