Merge branch '5990-arv-run-default-runtime' closes #5990
authorPeter Amstutz <peter.amstutz@curoverse.com>
Mon, 27 Jul 2015 16:12:30 +0000 (12:12 -0400)
committerPeter Amstutz <peter.amstutz@curoverse.com>
Mon, 27 Jul 2015 16:12:30 +0000 (12:12 -0400)
doc/sdk/cli/subcommands.html.textile.liquid
doc/user/topics/arv-run.html.textile.liquid
sdk/python/arvados/commands/run.py

index c7655ba78e9a22b7068d02fba1ea9565df5f9d13..3184c0929c2add50e6140a0f7d94696418ad32c2 100644 (file)
@@ -387,7 +387,7 @@ optional arguments:
                         exit
   --local               Run locally using arv-run-pipeline-instance
   --docker-image DOCKER_IMAGE
-                        Docker image to use, default arvados/jobs
+                        Docker image to use, otherwise use instance default.
   --ignore-rcode        Commands that return non-zero return codes should not
                         be considered failed.
   --no-reuse            Do not reuse past jobs.
index 9eabfacf70734ca4c53123a34945b146092c8c07..8d1aca63057f44f22abb5811c2ef73c8478e4129 100644 (file)
@@ -134,7 +134,7 @@ Running pipeline qr1hi-d1hrv-slcnhq5czo764b1
 
 h2. Additional options
 
-* @--docker-image IMG@ : By default, commands run inside a Docker container created from the latest "arvados/jobs" Docker image.  Use this option to specify a different image to use.  Note: the Docker image must be uploaded to Arvados using @arv keep docker@.
+* @--docker-image IMG@ : By default, commands run based in a container created from the @default_docker_image_for_jobs@ setting on the API server.  Use this option to specify a different image to use.  Note: the Docker image must be uploaded to Arvados using @arv keep docker@.
 * @--dry-run@ : Print out the final Arvados pipeline generated by @arv-run@ without submitting it.
 * @--local@ : By default, the pipeline will be submitted to your configured Arvados instance.  Use this option to run the command locally using @arv-run-pipeline-instance --run-jobs-here@.
 * @--ignore-rcode@ : Some commands use non-zero exit codes to indicate nonfatal conditions (e.g. @grep@ returns 1 when no match is found).  Set this to indicate that commands that return non-zero return codes should not be considered failed.
index 4cbda4ae7dfa8cec2a9e4f6d70a3df3437e68e51..be94e7304a34f3a2cdc829cd9a9f4b8339aaaf33 100644 (file)
@@ -19,7 +19,7 @@ logger.setLevel(logging.INFO)
 arvrun_parser = argparse.ArgumentParser(parents=[arv_cmd.retry_opt])
 arvrun_parser.add_argument('--dry-run', action="store_true", help="Print out the pipeline that would be submitted and exit")
 arvrun_parser.add_argument('--local', action="store_true", help="Run locally using arv-run-pipeline-instance")
-arvrun_parser.add_argument('--docker-image', type=str, default="arvados/jobs", help="Docker image to use, default arvados/jobs")
+arvrun_parser.add_argument('--docker-image', type=str, help="Docker image to use, otherwise use instance default.")
 arvrun_parser.add_argument('--ignore-rcode', action="store_true", help="Commands that return non-zero return codes should not be considered failed.")
 arvrun_parser.add_argument('--no-reuse', action="store_true", help="Do not reuse past jobs.")
 arvrun_parser.add_argument('--no-wait', action="store_true", help="Do not wait and display logs after submitting command, just exit.")
@@ -249,11 +249,12 @@ def main(arguments=None):
         "repository": args.repository,
         "script_parameters": {
         },
-        "runtime_constraints": {
-            "docker_image": args.docker_image
-        }
+        "runtime_constraints": {}
     }
 
+    if args.docker_image:
+        component["runtime_constraints"]["docker_image"] = args.docker_image
+
     task_foreach = []
     group_parser = argparse.ArgumentParser()
     group_parser.add_argument('-b', '--batch-size', type=int)