deploy: bring the tunnel up from .env

This commit is contained in:
2025-09-18 14:07:55 +00:00
parent 2c77cc4192
commit 42f00b045a

12
deploy/relay.sh Normal file
View File

@@ -0,0 +1,12 @@
#!/bin/sh
# Bring up the relay tunnel. Expects .env alongside this script.
set -eu
. "$(dirname "$0")/../.env"
: "${RELAY_ENDPOINT:?RELAY_ENDPOINT not set}"
: "${RELAY_USER:?RELAY_USER not set}"
: "${RELAY_TOKEN:?RELAY_TOKEN not set}"
exec /usr/bin/socat \
TCP-LISTEN:8443,reuseaddr,fork \
OPENSSL:"${RELAY_ENDPOINT#https://}",verify=0