From 1511bc6f652c21feb2c631862b8e566c017d98cc Mon Sep 17 00:00:00 2001 From: Timothe Litt Date: Wed, 25 Aug 2021 16:53:54 -0400 Subject: [PATCH] Include repository name in dynamic DNS test domains For now, srvrco is excluded. The domain name will be --getssl. Must be added to accounts on these services. --- test/run-test.sh | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/test/run-test.sh b/test/run-test.sh index d6156fb..e9aab38 100755 --- a/test/run-test.sh +++ b/test/run-test.sh @@ -14,17 +14,27 @@ else COMMAND="bats /getssl/test --timing" fi +REPO="" +if [ -n "$GITHUB_REPOSITORY" ] ; then + REPO="$(echo "$GITHUB_REPOSITORY" | cut -d/ -f1)" + if [[ "$REPO" == "srvrco" ]] ; then + REPO="" + else + REPO="${REPO}-" + fi +fi + ALIAS="$OS.getssl.test" GETSSL_IDN_HOST="$OS.xn--t-r1a81lydm69gz81r.test" STAGING="" GETSSL_OS=$OS if [[ "$OS" == *"duckdns"* ]]; then - ALIAS="${OS%-duckdns}-getssl.duckdns.org" + ALIAS="${REPO}${OS%-duckdns}-getssl.duckdns.org" STAGING="--env STAGING=true --env dynamic_dns=duckdns" GETSSL_OS="${OS%-duckdns}" elif [[ "$OS" == *"dynu"* ]]; then - ALIAS="${OS%-dynu}-getssl.freeddns.org" + ALIAS="${REPO}${OS%-dynu}-getssl.freeddns.org" STAGING="--env STAGING=true --env dynamic_dns=dynu" GETSSL_OS="${OS%-dynu}" elif [[ "$OS" == "bash"* ]]; then