Add .gitea/workflows/*.yaml
This commit is contained in:
@@ -17,21 +17,21 @@ jobs:
|
|||||||
echo "ACTIONS_RUNTIME_URL=${ACTIONS_RUNTIME_URL}"
|
echo "ACTIONS_RUNTIME_URL=${ACTIONS_RUNTIME_URL}"
|
||||||
|
|
||||||
# 2) Ping the cache status endpoint (works with either host IP or service name)
|
# 2) Ping the cache status endpoint (works with either host IP or service name)
|
||||||
- name: Probe cache server
|
#- name: Probe cache server
|
||||||
run: |
|
# run: |
|
||||||
URL="${ACTIONS_CACHE_URL%/}/_apis/artifactcache/status"
|
# URL="${ACTIONS_CACHE_URL%/}/_apis/artifactcache/status"
|
||||||
echo "Checking: $URL"
|
# echo "Checking: $URL"
|
||||||
if command -v curl >/dev/null 2>&1; then
|
# if command -v curl >/dev/null 2>&1; then
|
||||||
curl -fsS "$URL"
|
# curl -fsS "$URL"
|
||||||
else
|
# else
|
||||||
wget -qO- "$URL"
|
# wget -qO- "$URL"
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
# 3) Use the cache action with a stable key
|
# 3) Use the cache action with a stable key
|
||||||
# - First run => MISS (will SAVE at the end)
|
# - First run => MISS (will SAVE at the end)
|
||||||
# - Second run => HIT
|
# - Second run => HIT
|
||||||
- name: Use actions/cache
|
- name: Use actions/cache
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: ~/.cache/demo
|
path: ~/.cache/demo
|
||||||
key: cache-verify-${{ runner.os }}-v1
|
key: cache-verify-${{ runner.os }}-v1
|
||||||
|
|||||||
Reference in New Issue
Block a user