Skip to content

Commit

Permalink
fix router auto-renewal; fix router address IP SAN;
Browse files Browse the repository at this point in the history
  • Loading branch information
qrkourier committed Sep 24, 2024
1 parent 3b56d73 commit d437ccd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
7 changes: 6 additions & 1 deletion dist/dist-packages/linux/openziti-router/bootstrap.bash
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ makeConfig() {
ZITI_ROUTER_PORT \
ZITI_ROUTER_LISTENER_BIND_PORT="${ZITI_ROUTER_PORT}"

if [[ "${ZITI_ROUTER_ADVERTISED_ADDRESS}" =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
echo "DEBUG: ZITI_ROUTER_ADVERTISED_ADDRESS is an IPv4 address, setting ZITI_ROUTER_IP_OVERRIDE" >&3
export ZITI_ROUTER_IP_OVERRIDE="${ZITI_ROUTER_ADVERTISED_ADDRESS}"
unset ZITI_ROUTER_ADVERTISED_ADDRESS
fi

if [[ ! -s "${_config_file}" || "${1:-}" == --force ]]; then
# build config command
local -a _command=("ziti create config router ${ZITI_ROUTER_TYPE}" \
Expand All @@ -57,7 +63,6 @@ makeConfig() {
mv --no-clobber "${_config_file}"{,".${ZITI_BOOTSTRAP_NOW}.old"}
fi


exportZitiVars # export all ZITI_ vars to be used in bootstrap
# shellcheck disable=SC2068
${_command[@]}
Expand Down
5 changes: 1 addition & 4 deletions dist/dist-packages/linux/openziti-router/service.env
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,5 @@ ZITI_BOOTSTRAP_ENROLLMENT='true'
# BASH script that defines function bootstrap()
ZITI_ROUTER_BOOTSTRAP_BASH='/opt/openziti/etc/router/bootstrap.bash'

# renew server and client certificates every startup
ZITI_AUTO_RENEW_CERTS='true'

# additional arguments to the ExecStart command must be a non-empty string
ZITI_ARGS='--'
ZITI_ARGS='--extend'

0 comments on commit d437ccd

Please sign in to comment.