diff --git a/.github/workflows/check_pr.yml b/.github/workflows/check_pr.yml index 3afef15..203c048 100644 --- a/.github/workflows/check_pr.yml +++ b/.github/workflows/check_pr.yml @@ -29,7 +29,8 @@ jobs: TYPE=$(jq -r '.type // "CNAME"' ${jsonfile}) URL=$(jq -r '.url' ${jsonfile}) if [ ${TYPE} = "CNAME" ] || [ -z ${TYPE} ]; then - if echo ${URL} | grep -qE '^https?://[^/]*/.*'; then + # We add a `.*[^/]$` at the end to allow URLs that end with '/' + if echo ${URL} | grep -qE '^https?://[^/]*/.*[^/]$'; then echo "URL in ${jsonfile} must not contain subdirectories for CNAME records." exit 1 fi