7d0947d295
frontend-ci / secrets-scan (push) Successful in 5s
frontend-ci / lint (push) Successful in 15s
frontend-ci / typecheck (push) Successful in 18s
frontend-ci / sast (push) Successful in 12s
frontend-ci / fs-scan (push) Successful in 13s
frontend-ci / build (push) Successful in 40s
frontend-ci / push (push) Failing after 34s
Reviewed-on: #1
10 lines
406 B
Bash
Executable File
10 lines
406 B
Bash
Executable File
#!/bin/sh
|
|
# Render /config.js from the env var API_URL at container start.
|
|
# Runs as part of the official nginx:alpine /docker-entrypoint.d sequence,
|
|
# so nginx itself is launched by the upstream entrypoint after this script.
|
|
set -e
|
|
: "${API_URL:=/api/v1}"
|
|
export API_URL
|
|
envsubst < /etc/nginx/templates/config.js.template > /usr/share/nginx/html/config.js
|
|
echo "[config] API_URL=${API_URL} -> /config.js"
|