mirror of
https://github.com/actualbudget/actual.git
synced 2026-03-11 12:43:09 -05:00
Previously, the latest artifact list was requested unauthenticated using `ADD "https://api.github.com/..." /tmp/artifacts.json`. While this works locally, on GitHub’s servers it seems that the per-IP rate limit was exceeded. There isn’t a way to get Docker to pass the `Authorization` header that I know of, so this work has been moved to an external shell script that pulls down the relevant data.
15 lines
349 B
Bash
Executable File
15 lines
349 B
Bash
Executable File
#!/bin/bash
|
|
|
|
URL="https://api.github.com/repos/actualbudget/actual/actions/artifacts?name=actual-web&per_page=100"
|
|
|
|
if [ -n "$GITHUB_TOKEN" ]; then
|
|
curl -L -o artifacts.json --header "Authorization: Bearer ${GITHUB_TOKEN}" $URL
|
|
else
|
|
curl -L -o artifacts.json $URL
|
|
fi
|
|
|
|
if [ $? -ne 0 ]; then
|
|
echo "Failed to download artifacts.json"
|
|
exit 1
|
|
fi
|