Merge pull request 'Funktion "detect_compose_cmd" nachträglich committed.' (#3) from yamlfix into main
Reviewed-on: #3
This commit is contained in:
commit
f72287637b
@ -5,9 +5,9 @@
|
|||||||
# Synapse: https://git.techniverse.net/scriptos/livekit-ip-watch.git
|
# Synapse: https://git.techniverse.net/scriptos/livekit-ip-watch.git
|
||||||
# Autor: Patrick Asmus
|
# Autor: Patrick Asmus
|
||||||
# Web: https://www.cleveradmin.de
|
# Web: https://www.cleveradmin.de
|
||||||
# Version: 1.2
|
# Version: 1.2.1
|
||||||
# Datum: 27.10.2025
|
# Datum: 27.10.2025
|
||||||
# Modifikation: Funktionen "update_yaml_with_yq" und "update_yaml_fallback" überarbeitet
|
# Modifikation: Funktion "detect_compose_cmd" nachträglich committed.
|
||||||
#####################################################
|
#####################################################
|
||||||
|
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
@ -209,6 +209,14 @@ update_yaml_fallback() {
|
|||||||
mv "$tmp" "$CONFIG_FILE"
|
mv "$tmp" "$CONFIG_FILE"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
detect_compose_cmd() {
|
||||||
|
if command -v docker-compose >/dev/null 2>&1; then
|
||||||
|
echo "docker-compose"
|
||||||
|
else
|
||||||
|
echo "docker compose"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
restart_service() {
|
restart_service() {
|
||||||
if [[ "$RUNTIME" == "compose" ]]; then
|
if [[ "$RUNTIME" == "compose" ]]; then
|
||||||
local dir file
|
local dir file
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user