feat(ci): purge CDN cache after process-updates runs

process_cran_updates uploads fresh PACKAGES* to S3, but the CDN was only
purged by the daily update-package-index-* chain.
Between the two cron runs, edges kept serving the stale index,
so a binary that had just landed in S3 was effectively invisible
until the next index-update purge.

Adds the same purge step that update-package-index-* already uses,
parameterized per platform/arch.
This commit is contained in:
Patrick Schratz 2026-05-28 13:38:19 +02:00
commit 13d51ef4dd
Signed by: pat-s
GPG key ID: 3C6318841EF78925

View file

@ -75,3 +75,17 @@ steps:
operator: 'Equal'
value: 'true'
effect: 'NoSchedule'
- name: Purge CDN cache
image: reg.devxy.io/docker.io/library/alpine:3.23
environment:
BUNNYNET_API_KEY:
from_secret: BUNNYNET_API_KEY
SUBDOMAIN1: 'cran.devxy.io'
SUBDOMAIN2: 'cran.allianceswisspass.devxy.io'
SUBDOMAIN3: 'cran.rpkgs.com'
OS_ID: rhel8
ARCH: amd64
commands:
- apk add --no-cache -q bash curl
- bash scripts/purge_cdn_cache.sh "$BUNNYNET_API_KEY" "$ARCH" "$OS_ID" "$SUBDOMAIN1" "$SUBDOMAIN2" "$SUBDOMAIN3"