appstore-1panel/apps/stream-rec/0.7.2/scripts/upgrade.sh

18 lines
348 B
Bash
Raw Permalink Normal View History

#!/bin/bash
if [ -f .env ]; then
source .env
2024-07-27 18:10:05 +08:00
# setup-1 add default values
CURRENT_DIR=$(pwd)
sed -i '/^ENV_FILE=/d' .env
sed -i '/^GLOBAL_ENV_FILE=/d' .env
2024-07-27 18:10:05 +08:00
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
echo "GLOBAL_ENV_FILE=${CURRENT_DIR}/envs/global.env" >> .env
2024-07-27 18:10:05 +08:00
echo "Check Finish."
else
echo "Error: .env file not found."
fi