update project
This commit is contained in:
18
scripts/bitok-entrypoint.sh
Normal file
18
scripts/bitok-entrypoint.sh
Normal file
@@ -0,0 +1,18 @@
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
# Read Vault root token from shared volume (written by vault-init)
|
||||
TOKEN_FILE="/vault/file/root-token"
|
||||
if [ -f "$TOKEN_FILE" ]; then
|
||||
export VAULT_TOKEN=$(cat "$TOKEN_FILE" | tr -d '\n\r ')
|
||||
echo "[bitok-entrypoint] Loaded VAULT_TOKEN from $TOKEN_FILE"
|
||||
else
|
||||
echo "[bitok-entrypoint] WARNING: $TOKEN_FILE not found, using VAULT_TOKEN from env"
|
||||
fi
|
||||
|
||||
# Start BITOK auth service
|
||||
exec granian --interface asgi ${APP_MODULE:-src.main:app} \
|
||||
--host ${APP_HOST:-0.0.0.0} \
|
||||
--port ${APP_PORT:-8000} \
|
||||
--workers ${APP_WORKERS:-1} \
|
||||
--loop uvloop
|
||||
Reference in New Issue
Block a user