feat(map): derive station regions from GPS

This commit is contained in:
lingniu
2026-08-12 12:03:09 +08:00
parent f707e6ad68
commit 4c547757a7
8 changed files with 228 additions and 38 deletions
+3 -1
View File
@@ -15,7 +15,7 @@ test -f "$archive"
if ! id vehicle-map >/dev/null 2>&1; then
useradd --system --home-dir "$root" --shell /sbin/nologin vehicle-map
fi
mkdir -p "$root/releases" "$root/env"
mkdir -p "$root/releases" "$root/env" "$root/cache"
next="$root/releases/$release_id"
test ! -e "$next"
mkdir -p "$next"
@@ -32,6 +32,8 @@ chown -R root:vehicle-map "$next"
chmod -R u=rwX,g=rX,o= "$next"
chown root:vehicle-map "$root/env/vehicle-map.env"
chmod 0640 "$root/env/vehicle-map.env"
chown vehicle-map:vehicle-map "$root/cache"
chmod 0750 "$root/cache"
ln -s "$next" "$root/current.next"
python3 -c 'import os,sys; os.replace(sys.argv[1],sys.argv[2])' "$root/current.next" "$root/current"