diff --git a/phase1_post_check.sh b/phase1_post_check.sh index 94440bd..fcfbd63 100755 --- a/phase1_post_check.sh +++ b/phase1_post_check.sh @@ -55,15 +55,10 @@ run_check "API token valid (returns correct username)" check_token run_check "Organization '${GITEA_ORG_NAME}' exists" \ curl -sf -o /dev/null -H "Authorization: token ${GITEA_ADMIN_TOKEN}" "${GITEA_INTERNAL_URL}/api/v1/orgs/${GITEA_ORG_NAME}" -# Check 5: Gitea Actions admin runners API is accessible -# shellcheck disable=SC2329 -check_actions() { - local response - response=$(curl -sf -H "Authorization: token ${GITEA_ADMIN_TOKEN}" "${GITEA_INTERNAL_URL}/api/v1/admin/runners") - # Endpoint should return a JSON array (possibly empty) when available. - printf '%s' "$response" | jq -e 'type == "array"' >/dev/null -} -run_check "Gitea Actions admin runners API accessible" check_actions +# Check 5: Gitea API settings endpoint accessible +# Runners are verified in phase3_post_check.sh — phase 1 only deploys Gitea itself. +run_check "Gitea API settings endpoint accessible" \ + curl -sf -o /dev/null -H "Authorization: token ${GITEA_ADMIN_TOKEN}" "${GITEA_INTERNAL_URL}/api/v1/settings/api" # Summary printf '\n'