dropshell release 2025.0601.1752
Some checks failed
Dropshell Test / Build_and_Test (push) Failing after 16m46s
Some checks failed
Dropshell Test / Build_and_Test (push) Failing after 16m46s
This commit is contained in:
parent
49d61f0da0
commit
1da7dc7951
@ -93,6 +93,7 @@ _check_docker_installed() {
|
||||
|
||||
# Checks if a container (any state) exists. Returns 1 if not found.
|
||||
_is_container_exists() {
|
||||
[ -n "${1:-}" ] || { echo "_is_container_exists: Container name is empty" >&2; return 1; }
|
||||
if ! docker ps -a --format "{{.Names}}" | grep -q "^$1$"; then
|
||||
return 1
|
||||
fi
|
||||
@ -101,6 +102,7 @@ _is_container_exists() {
|
||||
|
||||
# Checks if a container is currently running. Returns 1 if not running.
|
||||
_is_container_running() {
|
||||
[ -n "${1:-}" ] || { echo "_is_container_running: Container name is empty" >&2; return 1; }
|
||||
if ! docker ps --format "{{.Names}}" | grep -q "^$1$"; then
|
||||
return 1
|
||||
fi
|
||||
|
@ -78,10 +78,13 @@ namespace dropshell
|
||||
if (!server_env.is_valid())
|
||||
return false; // should never hit this.
|
||||
|
||||
|
||||
std::string user = server_env.get_user_for_service(service);
|
||||
|
||||
std::string user = service_info.user;
|
||||
std::string remote_service_path = remotepath(server,user).service(service);
|
||||
|
||||
ASSERT(!remote_service_path.empty(), "Install_Service: Remote service path is empty for " + service + " on " + server);
|
||||
ASSERT(!user.empty(), "Install_Service: User is empty for " + service + " on " + server);
|
||||
|
||||
if (server_env.check_remote_dir_exists(remote_service_path, user))
|
||||
{ // uninstall the old service before we update the config or template!
|
||||
info << "Service " << service << " is already installed on " << server << std::endl;
|
||||
|
Loading…
x
Reference in New Issue
Block a user