2024-01-02 16:50:14 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
if [ ! -e "$DATA_DIR/.env" ] ; then
|
2024-10-16 09:41:44 +00:00
|
|
|
source_pass="$(LC_ALL=C tr -dc A-Za-z0-9 </dev/urandom | head -c 40)"
|
2024-01-02 16:50:14 +00:00
|
|
|
cat > "$DATA_DIR/.env" <<EOF
|
2024-10-16 09:41:44 +00:00
|
|
|
ICECAST_SOURCE_PASSWORD=$source_pass
|
|
|
|
ICECAST_ADMIN_PASSWORD=$(LC_ALL=C tr -dc A-Za-z0-9 </dev/urandom | head -c 40)
|
|
|
|
ICECAST_RELAY_PASSWORD=$(LC_ALL=C tr -dc A-Za-z0-9 </dev/urandom | head -c 40)
|
|
|
|
LIQUIDSOAP_SOURCE_PASSWORD=$(LC_ALL=C tr -dc A-Za-z0-9 </dev/urandom | head -c 40)
|
|
|
|
OMA_CONFIG_Client1EnteteNext="Authorization: Basic $(echo "source:$source_pass" | base64)"
|
2024-01-02 16:50:14 +00:00
|
|
|
EOF
|
|
|
|
fi
|