[ARVADOS] updated: acb0bd431ced4814b37f703ca63f2b39ad29c5df

Git user git at public.curoverse.com
Thu Mar 30 15:14:55 EDT 2017


Summary of changes:
 sdk/python/arvados/commands/migrate19.py | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

       via  acb0bd431ced4814b37f703ca63f2b39ad29c5df (commit)
      from  433c48edb1523809bb8d43e4fc40ebe1a177e103 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit acb0bd431ced4814b37f703ca63f2b39ad29c5df
Author: Peter Amstutz <peter.amstutz at curoverse.com>
Date:   Thu Mar 30 19:14:37 2017 +0000

    8567: Use arvados.config instead of os.environ.  Tweak disk space accounting output.

diff --git a/sdk/python/arvados/commands/migrate19.py b/sdk/python/arvados/commands/migrate19.py
index a9768a0..b792cb2 100644
--- a/sdk/python/arvados/commands/migrate19.py
+++ b/sdk/python/arvados/commands/migrate19.py
@@ -186,10 +186,10 @@ def main(arguments=None):
         dockercache = tempfile.mkdtemp()
         try:
             with tempfile.NamedTemporaryFile() as envfile:
-                envfile.write("ARVADOS_API_HOST=%s\n" % (os.environ["ARVADOS_API_HOST"]))
-                envfile.write("ARVADOS_API_TOKEN=%s\n" % (os.environ["ARVADOS_API_TOKEN"]))
-                if "ARVADOS_API_HOST_INSECURE" in os.environ:
-                    envfile.write("ARVADOS_API_HOST_INSECURE=%s\n" % (os.environ["ARVADOS_API_HOST_INSECURE"]))
+                envfile.write("ARVADOS_API_HOST=%s\n" % (arvados.config.get("ARVADOS_API_HOST")))
+                envfile.write("ARVADOS_API_TOKEN=%s\n" % (arvados.config.get("ARVADOS_API_TOKEN")))
+                if arvados.config.get("ARVADOS_API_HOST_INSECURE"):
+                    envfile.write("ARVADOS_API_HOST_INSECURE=%s\n" % (arvados.config.get("ARVADOS_API_HOST_INSECURE")))
                 envfile.flush()
 
                 dockercmd = ["docker", "run",
@@ -218,7 +218,7 @@ def main(arguments=None):
 
                 if initial_space:
                     isp = int(initial_space.group(1))
-                    logger.debug("Available space initially: %i MiB", (isp)/(2**20))
+                    logger.info("Available space initially: %i MiB", (isp)/(2**20))
                     if imgload_space:
                         sp = int(imgload_space.group(1))
                         logger.debug("Used after load: %i MiB", (isp-sp)/(2**20))
@@ -227,11 +227,11 @@ def main(arguments=None):
                         logger.debug("Used after upgrade: %i MiB", (isp-sp)/(2**20))
                     if keepdocker_space:
                         sp = int(keepdocker_space.group(1))
-                        logger.debug("Used after upload: %i MiB", (isp-sp)/(2**20))
+                        logger.info("Used after upload: %i MiB", (isp-sp)/(2**20))
 
                 if cleanup_space:
                     sp = int(cleanup_space.group(1))
-                    logger.info("Available after cleanup: %i MiB", (sp)/(2**20))
+                    logger.debug("Available after cleanup: %i MiB", (sp)/(2**20))
 
                 if proc.returncode != 0:
                     logger.error("Failed with return code %i", proc.returncode)

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list