added ip address found even runs within a another container
continuous-integration/drone/push Build was killed

This commit is contained in:
Gyorgy Berenyi
2026-03-11 09:52:54 +00:00
parent 4ee0771ef0
commit 802127a5f9
+5
View File
@@ -1,7 +1,12 @@
#!/bin/sh #!/bin/sh
SELECTOR=${JELLYFIN:-jellyfin} SELECTOR=${JELLYFIN:-jellyfin}
JELLYFIN_IP=$(hostname -i | awk '{print $1}') JELLYFIN_IP=$(hostname -i | awk '{print $1}')
if [ "$JELLYFIN_IP" == "" ]; then
JELLYFIN_IP=$(ip route get 1 | awk '{print $7; exit}')
fi
HOST_FILE=/etc/system/data/dns/hosts.local HOST_FILE=/etc/system/data/dns/hosts.local
EXISTS=$(grep -w -F $SELECTOR $HOST_FILE) EXISTS=$(grep -w -F $SELECTOR $HOST_FILE)