mirror of
https://github.com/aljazceru/btcpayserver-docker.git
synced 2026-01-31 12:14:28 +01:00
Make sure changedomain is called correctly
This commit is contained in:
@@ -3,6 +3,10 @@
|
||||
. /etc/profile.d/btcpay-env.sh
|
||||
|
||||
export NEW_HOST="$1"
|
||||
|
||||
if [[ "$NEW_HOST" == https:* ]] || [[ "$NEW_HOST" == http:* ]]; then
|
||||
echo "The domain should not start by http: or https:"
|
||||
else
|
||||
export OLD_HOST=`cat $BTCPAY_ENV_FILE | sed -n 's/^BTCPAY_HOST=\(.*\)$/\1/p'`
|
||||
echo "Changing domain from \"$OLD_HOST\" to \"$NEW_HOST\""
|
||||
|
||||
@@ -16,4 +20,5 @@ echo "BTCPAY_HOST=$BTCPAY_HOST" >> $BTCPAY_ENV_FILE
|
||||
echo "ACME_CA_URI=$ACME_CA_URI" >> $BTCPAY_ENV_FILE
|
||||
|
||||
cd "`dirname $BTCPAY_ENV_FILE`"
|
||||
docker-compose -f "$BTCPAY_DOCKER_COMPOSE" up -d
|
||||
docker-compose -f "$BTCPAY_DOCKER_COMPOSE" up -d
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user