fix: resolve symlinks before locating compose project

Use readlink -f to resolve the script's real path so that reload.sh
can be invoked through a symlink from any directory.
This commit is contained in:
lingkai5wu committed 2026-10-12 13:08:02 +08:00
1 parent f4e9f78837
commit bd9e2c03ae
1 file changed
+2 -1
+2 -1
View File
@@ -2,6 +2,7 @@
set -euo pipefail
cd -- "$(dirname -- "${BASH_SOURCE[0]}")"
source="$(readlink -f -- "${BASH_SOURCE[0]}")"
cd -- "$(dirname -- "$source")"
exec docker compose exec -T nginx sh -s <./.reload-in-container.sh