test: expand env vars in local config generator script
This commit is contained in:
parent
5d27068e06
commit
8fad322967
39
tools/easypanel-config-generator.localtest.sh
Executable file
39
tools/easypanel-config-generator.localtest.sh
Executable file
@ -0,0 +1,39 @@
|
||||
#!/bin/sh
|
||||
# Script de prueba: genera config en ./tmp_config/config.yml para validar el contenido
|
||||
|
||||
set -eu
|
||||
|
||||
CONFIG_DIR=./tmp_config
|
||||
CONFIG_PATH="$CONFIG_DIR/config.yml"
|
||||
|
||||
mkdir -p "$CONFIG_DIR"
|
||||
|
||||
cat > "$CONFIG_PATH" <<EOF
|
||||
general:
|
||||
public_url: "${LIBRETIME_GENERAL_PUBLIC_URL:-http://localhost:8080}"
|
||||
api_key: "${LIBRETIME_API_KEY:-}"
|
||||
secret_key: "${LIBRETIME_SECRET_KEY:-}"
|
||||
|
||||
database:
|
||||
host: ${POSTGRES_HOST:-postgres}
|
||||
port: ${POSTGRES_PORT:-5432}
|
||||
name: ${POSTGRES_DB:-libretime}
|
||||
user: ${POSTGRES_USER:-libretime}
|
||||
password: "${POSTGRES_PASSWORD:-}"
|
||||
|
||||
rabbitmq:
|
||||
host: ${RABBITMQ_HOST:-rabbitmq}
|
||||
port: ${RABBITMQ_PORT:-5672}
|
||||
vhost: ${RABBITMQ_DEFAULT_VHOST:-/libretime}
|
||||
user: ${RABBITMQ_DEFAULT_USER:-libretime}
|
||||
password: "${RABBITMQ_DEFAULT_PASS:-}"
|
||||
|
||||
icecast:
|
||||
source_password: "${ICECAST_SOURCE_PASSWORD:-changeme}"
|
||||
admin_password: "${ICECAST_ADMIN_PASSWORD:-changeme}"
|
||||
relay_password: "${ICECAST_RELAY_PASSWORD:-changeme}"
|
||||
admin_user: "${ICECAST_ADMIN_USER:-admin}"
|
||||
hostname: "${ICECAST_HOSTNAME:-localhost}"
|
||||
EOF
|
||||
|
||||
echo "wrote $CONFIG_PATH"
|
||||
Loading…
x
Reference in New Issue
Block a user