BTCPayserver upates.
This commit is contained in:
parent
919acbf172
commit
ddcc119030
@ -37,6 +37,7 @@ export CLAMSSERVER_BACKUP_DISK_SIZE_GB=20
|
|||||||
export CLAMSSERVER_DOCKER_DISK_SIZE_GB=100
|
export CLAMSSERVER_DOCKER_DISK_SIZE_GB=100
|
||||||
|
|
||||||
export WWW_HOSTNAME="www"
|
export WWW_HOSTNAME="www"
|
||||||
|
export BTCPAY_SERVER_HOSTNAME="btcpayserver"
|
||||||
export CLAMS_SERVER_HOSTNAME="clamsserver"
|
export CLAMS_SERVER_HOSTNAME="clamsserver"
|
||||||
export BTCPAY_HOSTNAME_IN_CERT="btcpay"
|
export BTCPAY_HOSTNAME_IN_CERT="btcpay"
|
||||||
export NEXTCLOUD_HOSTNAME="nextcloud"
|
export NEXTCLOUD_HOSTNAME="nextcloud"
|
||||||
|
@ -209,9 +209,15 @@ if [ "$VIRTUAL_MACHINE" != base ]; then
|
|||||||
match:
|
match:
|
||||||
macaddress: ${MAC_ADDRESS_TO_PROVISION}
|
macaddress: ${MAC_ADDRESS_TO_PROVISION}
|
||||||
set-name: enp5s0
|
set-name: enp5s0
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
# TODO try to get DHCP working reliably.
|
||||||
|
if [ "$VIRTUAL_MACHINE" = btcpayserver ]; then
|
||||||
|
cat >> "$YAML_PATH" <<EOF
|
||||||
enp6s0:
|
enp6s0:
|
||||||
dhcp4: true
|
addresses:
|
||||||
|
- 10.10.10.66/24
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
@ -41,11 +41,8 @@ SKIP_BASE_IMAGE_CREATION=false
|
|||||||
SKIP_WWW=false
|
SKIP_WWW=false
|
||||||
RESTORE_WWW=false
|
RESTORE_WWW=false
|
||||||
RESTORE_CERTS=false
|
RESTORE_CERTS=false
|
||||||
BACKUP_CERTS=false
|
BACKUP_BTCPAY=true
|
||||||
BACKUP_BTCPAY=false
|
SKIP_BTCPAYSERVER=false
|
||||||
BACKUP_CERTS=false
|
|
||||||
BACKUP_APPS=false
|
|
||||||
BACKUP_BTCPAY=false
|
|
||||||
BACKUP_BTCPAY_ARCHIVE_PATH=
|
BACKUP_BTCPAY_ARCHIVE_PATH=
|
||||||
RESTORE_BTCPAY=false
|
RESTORE_BTCPAY=false
|
||||||
SKIP_BTCPAY=false
|
SKIP_BTCPAY=false
|
||||||
@ -53,7 +50,7 @@ UPDATE_BTCPAY=false
|
|||||||
REMOTE_NAME="$(lxc remote get-default)"
|
REMOTE_NAME="$(lxc remote get-default)"
|
||||||
STOP_SERVICES=false
|
STOP_SERVICES=false
|
||||||
USER_SAYS_YES=false
|
USER_SAYS_YES=false
|
||||||
RESTART_FRONT_END=true
|
BTCPAY_SERVER_MAC_ADDRESS=
|
||||||
|
|
||||||
# grab any modifications from the command line.
|
# grab any modifications from the command line.
|
||||||
for i in "$@"; do
|
for i in "$@"; do
|
||||||
@ -72,9 +69,10 @@ for i in "$@"; do
|
|||||||
RESTORE_BTCPAY=true
|
RESTORE_BTCPAY=true
|
||||||
shift
|
shift
|
||||||
;;
|
;;
|
||||||
--backup-www)
|
--skip-btcpayserver)
|
||||||
BACKUP_CERTS=true
|
SKIP_BTCPAYSERVER=true
|
||||||
BACKUP_APPS=true
|
shift
|
||||||
|
;;
|
||||||
shift
|
shift
|
||||||
;;
|
;;
|
||||||
--backup-btcpayserver)
|
--backup-btcpayserver)
|
||||||
@ -250,7 +248,7 @@ WWW_SERVER_MAC_ADDRESS=
|
|||||||
# WWW_SERVER_CPU_COUNT="6"
|
# WWW_SERVER_CPU_COUNT="6"
|
||||||
# WWW_SERVER_MEMORY_MB="4096"
|
# WWW_SERVER_MEMORY_MB="4096"
|
||||||
|
|
||||||
BTCPAYSERVER_MAC_ADDRESS=
|
BTCPAY_SERVER_MAC_ADDRESS=
|
||||||
# BTCPAY_SERVER_CPU_COUNT="4"
|
# BTCPAY_SERVER_CPU_COUNT="4"
|
||||||
# BTCPAY_SERVER_MEMORY_MB="4096"
|
# BTCPAY_SERVER_MEMORY_MB="4096"
|
||||||
|
|
||||||
@ -281,9 +279,8 @@ if [ -z "$WWW_SERVER_MAC_ADDRESS" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
if [ -z "$BTCPAYSERVER_MAC_ADDRESS" ]; then
|
if [ -z "$BTCPAY_SERVER_MAC_ADDRESS" ]; then
|
||||||
echo "ERROR: the BTCPAYSERVER_MAC_ADDRESS is not specified. Check your project.conf."
|
echo "WARNING: the BTCPAY_SERVER_MAC_ADDRESS is not specified. Check your project.conf."
|
||||||
exit 1
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
@ -320,6 +317,9 @@ fi
|
|||||||
|
|
||||||
for VIRTUAL_MACHINE in www btcpayserver clamsserver; do
|
for VIRTUAL_MACHINE in www btcpayserver clamsserver; do
|
||||||
|
|
||||||
|
if [ "$VIRTUAL_MACHINE" = btcpayserver ] && [ -z "$BTCPAY_SERVER_MAC_ADDRESS" ]; then
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "$VIRTUAL_MACHINE" = clamsserver ] && [ -z "$CLAMS_SERVER_MAC_ADDRESS" ]; then
|
if [ "$VIRTUAL_MACHINE" = clamsserver ] && [ -z "$CLAMS_SERVER_MAC_ADDRESS" ]; then
|
||||||
continue
|
continue
|
||||||
@ -384,6 +384,11 @@ for VIRTUAL_MACHINE in www btcpayserver clamsserver; do
|
|||||||
VPS_HOSTNAME="$WWW_HOSTNAME"
|
VPS_HOSTNAME="$WWW_HOSTNAME"
|
||||||
MAC_ADDRESS_TO_PROVISION="$WWW_SERVER_MAC_ADDRESS"
|
MAC_ADDRESS_TO_PROVISION="$WWW_SERVER_MAC_ADDRESS"
|
||||||
|
|
||||||
|
elif [ "$VIRTUAL_MACHINE" = btcpayserver ] && [ -n "$BTCPAY_SERVER_MAC_ADDRESS" ]; then
|
||||||
|
FQDN="$BTCPAY_SERVER_HOSTNAME.$DOMAIN_NAME"
|
||||||
|
VPS_HOSTNAME="$BTCPAY_SERVER_HOSTNAME"
|
||||||
|
MAC_ADDRESS_TO_PROVISION="$BTCPAY_SERVER_MAC_ADDRESS"
|
||||||
|
|
||||||
elif [ "$VIRTUAL_MACHINE" = clamsserver ] && [ -n "$CLAMS_SERVER_MAC_ADDRESS" ]; then
|
elif [ "$VIRTUAL_MACHINE" = clamsserver ] && [ -n "$CLAMS_SERVER_MAC_ADDRESS" ]; then
|
||||||
FQDN="$CLAMS_SERVER_HOSTNAME.$DOMAIN_NAME"
|
FQDN="$CLAMS_SERVER_HOSTNAME.$DOMAIN_NAME"
|
||||||
VPS_HOSTNAME="$CLAMS_SERVER_HOSTNAME"
|
VPS_HOSTNAME="$CLAMS_SERVER_HOSTNAME"
|
||||||
@ -424,6 +429,26 @@ for DOMAIN_NAME in ${OTHER_SITES_LIST//,/ }; do
|
|||||||
stub_site_definition
|
stub_site_definition
|
||||||
done
|
done
|
||||||
|
|
||||||
|
if [ "$SKIP_BTCPAYSERVER" = false ]; then
|
||||||
|
if [ -n "$BTCPAY_SERVER_MAC_ADDRESS" ]; then
|
||||||
|
export DOCKER_HOST="ssh://ubuntu@$BTCPAY_SERVER_FQDN"
|
||||||
|
./project/btcpayserver/go.sh
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$SKIP_WWW" = false ]; then
|
||||||
|
# now let's run the www and btcpay-specific provisioning scripts.
|
||||||
|
if [ -n "$WWW_SERVER_MAC_ADDRESS" ]; then
|
||||||
|
export DOCKER_HOST="ssh://ubuntu@$WWW_FQDN"
|
||||||
|
|
||||||
|
# enable docker swarm mode so we can support docker stacks.
|
||||||
|
if docker info | grep -q "Swarm: inactive"; then
|
||||||
|
docker swarm init --advertise-addr enp6s0
|
||||||
|
fi
|
||||||
|
|
||||||
|
./project/www/go.sh
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
# now let's run the www and btcpay-specific provisioning scripts.
|
# now let's run the www and btcpay-specific provisioning scripts.
|
||||||
if [ -n "$CLAMS_SERVER_MAC_ADDRESS" ]; then
|
if [ -n "$CLAMS_SERVER_MAC_ADDRESS" ]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user