From: Tom Clegg Date: Wed, 22 Apr 2020 20:50:06 +0000 (-0400) Subject: 16343: Fix handling of local CR creation when LoginCluster is used. X-Git-Tag: 2.1.0~236^2 X-Git-Url: https://git.arvados.org/arvados.git/commitdiff_plain/e884be43ee0209ff28fdc3c105910f78edf64996?hp=8332284f3bb68bcf779d689129b8df9c911d5c47 16343: Fix handling of local CR creation when LoginCluster is used. Arvados-DCO-1.1-Signed-off-by: Tom Clegg --- diff --git a/lib/controller/fed_containers.go b/lib/controller/fed_containers.go index a923f757f2..c62cea1168 100644 --- a/lib/controller/fed_containers.go +++ b/lib/controller/fed_containers.go @@ -42,13 +42,11 @@ func remoteContainerRequestCreate( return true } - if *clusterId == "" { - *clusterId = h.handler.Cluster.ClusterID - } - - if strings.HasPrefix(currentUser.Authorization.UUID, h.handler.Cluster.ClusterID) && - *clusterId == h.handler.Cluster.ClusterID { - // local user submitting container request to local cluster + if *clusterId == "" || *clusterId == h.handler.Cluster.ClusterID { + // Submitting container request to local cluster. No + // need to set a runtime_token (rails api will create + // one when the container runs) or do a remote cluster + // request. return false }