From e95cc08f5404ec0bcde9f9ea0725c97a868414f2 Mon Sep 17 00:00:00 2001 From: andres-portainer Date: Mon, 20 Nov 2023 14:47:17 -0300 Subject: [PATCH] Change the condition. --- api/stacks/deployments/deploy.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/stacks/deployments/deploy.go b/api/stacks/deployments/deploy.go index e111e8001..b5111de02 100644 --- a/api/stacks/deployments/deploy.go +++ b/api/stacks/deployments/deploy.go @@ -11,7 +11,6 @@ import ( "github.com/portainer/portainer/api/dataservices" "github.com/portainer/portainer/api/git/update" "github.com/portainer/portainer/api/http/security" - "github.com/portainer/portainer/api/internal/endpointutils" "github.com/portainer/portainer/api/scheduler" "github.com/portainer/portainer/api/stacks/stackutils" @@ -172,7 +171,8 @@ func getUserRegistries(datastore dataservices.DataStore, user *portainer.User, e } func isEnvironmentOnline(endpoint *portainer.Endpoint) bool { - if endpointutils.IsLocalEndpoint(endpoint) { + if endpoint.Type != portainer.AgentOnDockerEnvironment && + endpoint.Type != portainer.AgentOnKubernetesEnvironment { return true }