[ARVADOS] updated: 1.3.0-1397-gdb1fe4b4a

Git user git at public.curoverse.com
Fri Jul 26 20:32:01 UTC 2019


Summary of changes:

       via  db1fe4b4a8fa675e26a7f54bbdf98bec195ffbd3 (commit)
       via  a8f06008a55aa4182ec1199c95c9353a4bc3b0dc (commit)
      from  e883ee5be779b41f6dc7c4099c64ccae8198cf18 (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 db1fe4b4a8fa675e26a7f54bbdf98bec195ffbd3
Merge: a8f06008a e883ee5be
Author: Eric Biagiotti <ebiagiotti at veritasgenetics.com>
Date:   Fri Jul 26 16:31:58 2019 -0400

    Merge remote-tracking branch 'origin/14813-wb2-config' into 14813-wb2-config
    
    refs #14813
    2
    14813
    2
    
    Arvados-DCO-1.1-Signed-off-by: Eric Biagiotti <ebiagiotti at veritasgenetics.com>


commit a8f06008a55aa4182ec1199c95c9353a4bc3b0dc
Author: Eric Biagiotti <ebiagiotti at veritasgenetics.com>
Date:   Thu Jul 25 17:18:56 2019 -0400

    14813: Adds ClusterID to config export
    
    Arvados-DCO-1.1-Signed-off-by: Eric Biagiotti <ebiagiotti at veritasgenetics.com>

diff --git a/lib/config/export.go b/lib/config/export.go
index b79dec4d9..ed330454c 100644
--- a/lib/config/export.go
+++ b/lib/config/export.go
@@ -26,6 +26,10 @@ func ExportJSON(w io.Writer, cluster *arvados.Cluster) error {
 	if err != nil {
 		return err
 	}
+
+	// ClusterID is not marshalled by default (see `json:"-"`).
+	// Add it back here so it is included in the exported config.
+	m["ClusterID"] = cluster.ClusterID
 	err = redactUnsafe(m, "", "")
 	if err != nil {
 		return err
@@ -55,54 +59,55 @@ func ExportJSON(w io.Writer, cluster *arvados.Cluster) error {
 // exists.
 var whitelist = map[string]bool{
 	// | sort -t'"' -k2,2
-	"API":                                          true,
-	"API.AsyncPermissionsUpdateInterval":           false,
-	"API.DisabledAPIs":                             false,
-	"API.MaxIndexDatabaseRead":                     false,
-	"API.MaxItemsPerResponse":                      true,
-	"API.MaxRequestAmplification":                  false,
-	"API.MaxRequestSize":                           true,
-	"API.RailsSessionSecretToken":                  false,
-	"API.RequestTimeout":                           true,
-	"AuditLogs":                                    false,
-	"AuditLogs.MaxAge":                             false,
-	"AuditLogs.MaxDeleteBatch":                     false,
-	"AuditLogs.UnloggedAttributes":                 false,
-	"Collections":                                  true,
-	"Collections.BlobSigning":                      true,
-	"Collections.BlobSigningKey":                   false,
-	"Collections.BlobSigningTTL":                   true,
-	"Collections.CollectionVersioning":             false,
-	"Collections.DefaultReplication":               true,
-	"Collections.DefaultTrashLifetime":             true,
-	"Collections.ManagedProperties":                true,
-	"Collections.ManagedProperties.*":              true,
-	"Collections.ManagedProperties.*.*":            true,
-	"Collections.PreserveVersionIfIdle":            true,
-	"Collections.TrashSweepInterval":               false,
-	"Collections.TrustAllContent":                  false,
-	"Containers":                                   true,
-	"Containers.CloudVMs":                          false,
-	"Containers.DefaultKeepCacheRAM":               true,
-	"Containers.DispatchPrivateKey":                false,
-	"Containers.JobsAPI":                           true,
-	"Containers.JobsAPI.CrunchJobUser":             false,
-	"Containers.JobsAPI.CrunchJobWrapper":          false,
-	"Containers.JobsAPI.CrunchRefreshTrigger":      false,
-	"Containers.JobsAPI.DefaultDockerImage":        false,
-	"Containers.JobsAPI.Enable":                    true,
-	"Containers.JobsAPI.GitInternalDir":            false,
-	"Containers.JobsAPI.ReuseJobIfOutputsDiffer":   false,
-	"Containers.Logging":                           false,
-	"Containers.LogReuseDecisions":                 false,
-	"Containers.MaxComputeVMs":                     false,
-	"Containers.MaxDispatchAttempts":               false,
-	"Containers.MaxRetryAttempts":                  true,
-	"Containers.SLURM":                             false,
-	"Containers.StaleLockTimeout":                  false,
-	"Containers.SupportedDockerImageFormats":       true,
-	"Containers.UsePreemptibleInstances":           true,
-	"EnableBetaController14287":                    false,
+	"ClusterID": true,
+	"API":       true,
+	"API.AsyncPermissionsUpdateInterval":         false,
+	"API.DisabledAPIs":                           false,
+	"API.MaxIndexDatabaseRead":                   false,
+	"API.MaxItemsPerResponse":                    true,
+	"API.MaxRequestAmplification":                false,
+	"API.MaxRequestSize":                         true,
+	"API.RailsSessionSecretToken":                false,
+	"API.RequestTimeout":                         true,
+	"AuditLogs":                                  false,
+	"AuditLogs.MaxAge":                           false,
+	"AuditLogs.MaxDeleteBatch":                   false,
+	"AuditLogs.UnloggedAttributes":               false,
+	"Collections":                                true,
+	"Collections.BlobSigning":                    true,
+	"Collections.BlobSigningKey":                 false,
+	"Collections.BlobSigningTTL":                 true,
+	"Collections.CollectionVersioning":           false,
+	"Collections.DefaultReplication":             true,
+	"Collections.DefaultTrashLifetime":           true,
+	"Collections.ManagedProperties":              true,
+	"Collections.ManagedProperties.*":            true,
+	"Collections.ManagedProperties.*.*":          true,
+	"Collections.PreserveVersionIfIdle":          true,
+	"Collections.TrashSweepInterval":             false,
+	"Collections.TrustAllContent":                false,
+	"Containers":                                 true,
+	"Containers.CloudVMs":                        false,
+	"Containers.DefaultKeepCacheRAM":             true,
+	"Containers.DispatchPrivateKey":              false,
+	"Containers.JobsAPI":                         true,
+	"Containers.JobsAPI.CrunchJobUser":           false,
+	"Containers.JobsAPI.CrunchJobWrapper":        false,
+	"Containers.JobsAPI.CrunchRefreshTrigger":    false,
+	"Containers.JobsAPI.DefaultDockerImage":      false,
+	"Containers.JobsAPI.Enable":                  true,
+	"Containers.JobsAPI.GitInternalDir":          false,
+	"Containers.JobsAPI.ReuseJobIfOutputsDiffer": false,
+	"Containers.Logging":                         false,
+	"Containers.LogReuseDecisions":               false,
+	"Containers.MaxComputeVMs":                   false,
+	"Containers.MaxDispatchAttempts":             false,
+	"Containers.MaxRetryAttempts":                true,
+	"Containers.SLURM":                           false,
+	"Containers.StaleLockTimeout":                false,
+	"Containers.SupportedDockerImageFormats":     true,
+	"Containers.UsePreemptibleInstances":         true,
+	"EnableBetaController14287":                  false,
 	"Git":                                          false,
 	"InstanceTypes":                                true,
 	"InstanceTypes.*":                              true,
diff --git a/lib/config/export_test.go b/lib/config/export_test.go
index e12fbdc7f..7af117e38 100644
--- a/lib/config/export_test.go
+++ b/lib/config/export_test.go
@@ -20,11 +20,12 @@ func (s *ExportSuite) TestExport(c *check.C) {
 	confdata := strings.Replace(string(DefaultYAML), "SAMPLE", "testkey", -1)
 	cfg, err := testLoader(c, confdata, nil).Load()
 	c.Assert(err, check.IsNil)
-	cluster := cfg.Clusters["xxxxx"]
+	cluster, err := cfg.GetCluster("xxxxx")
+	c.Assert(err, check.IsNil)
 	cluster.ManagementToken = "abcdefg"
 
 	var exported bytes.Buffer
-	err = ExportJSON(&exported, &cluster)
+	err = ExportJSON(&exported, cluster)
 	c.Check(err, check.IsNil)
 	if err != nil {
 		c.Logf("If all the new keys are safe, add these to whitelist in export.go:")
@@ -32,5 +33,7 @@ func (s *ExportSuite) TestExport(c *check.C) {
 			c.Logf("\t%q: true,", strings.Replace(k, `"`, "", -1))
 		}
 	}
-	c.Check(exported.String(), check.Not(check.Matches), `(?ms).*abcdefg.*`)
+	var exportedStr = exported.String()
+	c.Check(exportedStr, check.Matches, `(?ms).*ClusterID":"xxxxx.*`)
+	c.Check(exportedStr, check.Not(check.Matches), `(?ms).*abcdefg.*`)
 }

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list