[ARVADOS] updated: 2.1.0-1060-gf2ee5bac3

Git user git at public.arvados.org
Thu Jul 15 19:59:14 UTC 2021


Summary of changes:
 doc/admin/upgrading.html.textile.liquid              |  6 +++++-
 .../crunch-dispatch-local/crunch-dispatch-local.go   | 20 ++++++++++++++++++++
 2 files changed, 25 insertions(+), 1 deletion(-)

       via  f2ee5bac37391ce9fe084306da332becd7620ca7 (commit)
      from  753d479b0b5960674bf8e5a27ee98f68b3cd06ce (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 f2ee5bac37391ce9fe084306da332becd7620ca7
Author: Peter Amstutz <peter.amstutz at curii.com>
Date:   Thu Jul 15 15:58:45 2021 -0400

    17816: crunch-dispatch-local uses cluster config.
    
    Added upgrade note.
    
    Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz at curii.com>

diff --git a/doc/admin/upgrading.html.textile.liquid b/doc/admin/upgrading.html.textile.liquid
index 13f093394..3c283c354 100644
--- a/doc/admin/upgrading.html.textile.liquid
+++ b/doc/admin/upgrading.html.textile.liquid
@@ -35,10 +35,14 @@ TODO: extract this information based on git commit messages and generate changel
 <div class="releasenotes">
 </notextile>
 
-h2(#main). development main (as of 2021-06-03)
+h2(#main). development main (as of 2021-07-15)
 
 "Upgrading from 2.2.0":#v2_2_0
 
+h3. crunch-dispatch-local now requires config.yml
+
+The @crunch-dispatch-local@ dispatcher now reads the API host and token from the system wide @/etc/arvados/config.yml@ .  It will fail to start that file is not found or not readable.
+
 h2(#v2_2_0). v2.2.0 (2021-06-03)
 
 "Upgrading from 2.1.0":#v2_1_0
diff --git a/services/crunch-dispatch-local/crunch-dispatch-local.go b/services/crunch-dispatch-local/crunch-dispatch-local.go
index 4a45f1054..c202e683f 100644
--- a/services/crunch-dispatch-local/crunch-dispatch-local.go
+++ b/services/crunch-dispatch-local/crunch-dispatch-local.go
@@ -86,6 +86,26 @@ func doMain() error {
 
 	runningCmds = make(map[string]*exec.Cmd)
 
+	var client arvados.Client
+	client.APIHost = cluster.Services.Controller.ExternalURL.Host
+	client.AuthToken = cluster.SystemRootToken
+	client.Insecure = cluster.TLS.Insecure
+
+	if client.APIHost != "" || client.AuthToken != "" {
+		// Copy real configs into env vars so [a]
+		// MakeArvadosClient() uses them, and [b] they get
+		// propagated to crunch-run via SLURM.
+		os.Setenv("ARVADOS_API_HOST", client.APIHost)
+		os.Setenv("ARVADOS_API_TOKEN", client.AuthToken)
+		os.Setenv("ARVADOS_API_HOST_INSECURE", "")
+		if client.Insecure {
+			os.Setenv("ARVADOS_API_HOST_INSECURE", "1")
+		}
+		os.Setenv("ARVADOS_EXTERNAL_CLIENT", "")
+	} else {
+		logger.Warnf("Client credentials missing from config, so falling back on environment variables (deprecated).")
+	}
+
 	arv, err := arvadosclient.MakeArvadosClient()
 	if err != nil {
 		logger.Errorf("error making Arvados client: %v", err)

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list