fix(docker): harden frontend runtime config
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
|
||||
assignment=$(sed \
|
||||
-e 's/^window\.__THOTHII_CONFIG__ = //' \
|
||||
-e 's/;$//' \
|
||||
/usr/share/nginx/html/config.js)
|
||||
|
||||
printf '%s\n' "$assignment" \
|
||||
| jq -e --arg expected "${BACKEND_BASE_URL:-/api}" \
|
||||
'type == "object" and keys == ["backendBaseUrl"] and .backendBaseUrl == $expected' \
|
||||
>/dev/null
|
||||
|
||||
printf '%s\n' "frontend runtime config smoke: ok"
|
||||
Reference in New Issue
Block a user