chore(script): fix registry verification
This commit is contained in:
parent
0c28231c3b
commit
7f28c5b047
@ -22,12 +22,17 @@ corepack pnpm install
|
|||||||
corepack pnpm test
|
corepack pnpm test
|
||||||
|
|
||||||
echo "Verifying HTTP responses..."
|
echo "Verifying HTTP responses..."
|
||||||
|
declare -A extra_headers=(
|
||||||
|
[https://gitea.bytelyst.com/api/packages/ByteLyst/npm/]="-H Authorization: token ${GITEA_NPM_TOKEN}"
|
||||||
|
)
|
||||||
|
|
||||||
for url in \
|
for url in \
|
||||||
https://api.bytelyst.com/platform/health \
|
https://api.bytelyst.com/platform/health \
|
||||||
https://gitea.bytelyst.com/api/packages/ByteLyst/npm/ \
|
https://gitea.bytelyst.com/api/packages/ByteLyst/npm/ \
|
||||||
https://ollama.bytelyst.com/api/version \
|
https://ollama.bytelyst.com/api/version \
|
||||||
; do
|
; do
|
||||||
if curl -sSfI "$url" >/tmp/last-curl.out; then
|
headers=${extra_headers[$url]:-}
|
||||||
|
if curl -sSfI $headers "$url" >/tmp/last-curl.out; then
|
||||||
status=$(head -n1 /tmp/last-curl.out)
|
status=$(head -n1 /tmp/last-curl.out)
|
||||||
echo "$url -> $status"
|
echo "$url -> $status"
|
||||||
else
|
else
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user