dropshell release 2025.0601.1752
Some checks failed
Dropshell Test / Build_and_Test (push) Failing after 16m46s

This commit is contained in:
Your Name 2025-06-01 17:53:06 +12:00
parent 49d61f0da0
commit 1da7dc7951
2 changed files with 7 additions and 2 deletions

View File

@ -93,6 +93,7 @@ _check_docker_installed() {
# Checks if a container (any state) exists. Returns 1 if not found. # Checks if a container (any state) exists. Returns 1 if not found.
_is_container_exists() { _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 if ! docker ps -a --format "{{.Names}}" | grep -q "^$1$"; then
return 1 return 1
fi fi
@ -101,6 +102,7 @@ _is_container_exists() {
# Checks if a container is currently running. Returns 1 if not running. # Checks if a container is currently running. Returns 1 if not running.
_is_container_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 if ! docker ps --format "{{.Names}}" | grep -q "^$1$"; then
return 1 return 1
fi fi

View File

@ -79,9 +79,12 @@ namespace dropshell
return false; // should never hit this. 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); 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)) if (server_env.check_remote_dir_exists(remote_service_path, user))
{ // uninstall the old service before we update the config or template! { // uninstall the old service before we update the config or template!
info << "Service " << service << " is already installed on " << server << std::endl; info << "Service " << service << " is already installed on " << server << std::endl;