fix(ci): clear stale pkgcache metadata at start of build-all runs
This commit is contained in:
parent
b53a24614b
commit
c338ce2f10
2 changed files with 20 additions and 11 deletions
|
|
@ -4,19 +4,19 @@
|
||||||
# they are merged with build-all-versions' identical declarations.
|
# they are merged with build-all-versions' identical declarations.
|
||||||
variables:
|
variables:
|
||||||
target_arch:
|
target_arch:
|
||||||
description: "Architecture to build."
|
description: 'Architecture to build.'
|
||||||
options:
|
options:
|
||||||
- amd64
|
- amd64
|
||||||
- arm64
|
- arm64
|
||||||
default: amd64
|
default: amd64
|
||||||
OS:
|
OS:
|
||||||
description: "Base OS image name (e.g. alpine, redhat, ubuntu)."
|
description: 'Base OS image name (e.g. alpine, redhat, ubuntu).'
|
||||||
default: alpine
|
default: alpine
|
||||||
OS_VERSION:
|
OS_VERSION:
|
||||||
description: "OS version / image tag (e.g. 3.24, 9, jammy, noble)."
|
description: 'OS version / image tag (e.g. 3.24, 9, jammy, noble).'
|
||||||
default: "3.24"
|
default: '3.24'
|
||||||
R_VERSION:
|
R_VERSION:
|
||||||
description: "Primary R version under /opt/R."
|
description: 'Primary R version under /opt/R.'
|
||||||
options:
|
options:
|
||||||
- 4.5.3
|
- 4.5.3
|
||||||
- 4.4.3
|
- 4.4.3
|
||||||
|
|
@ -60,6 +60,10 @@ steps:
|
||||||
commands:
|
commands:
|
||||||
# one-time full wipe to fix corrupted .so files from previous failed builds
|
# one-time full wipe to fix corrupted .so files from previous failed builds
|
||||||
# - rm -rf /mnt/cache/R-pkgs
|
# - rm -rf /mnt/cache/R-pkgs
|
||||||
|
# Clear churny pkgcache metadata left by a prior crashed run (the "patched"
|
||||||
|
# repo mints a new hash per PACKAGES change -> unbounded pkgs-*.rds/patched-*).
|
||||||
|
# Keep pkg/ downloads and the stable CRAN/BioC/INLA repo dirs.
|
||||||
|
- rm -rf /mnt/cache/pkgcache/R/pkgcache/_metadata/patched-* /mnt/cache/pkgcache/R/pkgcache/_metadata/pkgs-*.rds || true
|
||||||
- mkdir -p /mnt/cache/pkgcache /mnt/cache/R-pkgs /mnt/cache/ccache /mnt/cache/packages
|
- mkdir -p /mnt/cache/pkgcache /mnt/cache/R-pkgs /mnt/cache/ccache /mnt/cache/packages
|
||||||
- git clone -q https://pat-s:$$REPO_RO_TOKEN@git.devxy.io/devxy/build-cran-binaries.git .
|
- git clone -q https://pat-s:$$REPO_RO_TOKEN@git.devxy.io/devxy/build-cran-binaries.git .
|
||||||
- git clone -q https://codefloe.com/rpkgs/bincraft.git /tmp/bincraft
|
- git clone -q https://codefloe.com/rpkgs/bincraft.git /tmp/bincraft
|
||||||
|
|
|
||||||
|
|
@ -5,19 +5,19 @@
|
||||||
# Skip list lives in local/excluded-packages.json (read by local/build-all.R).
|
# Skip list lives in local/excluded-packages.json (read by local/build-all.R).
|
||||||
variables:
|
variables:
|
||||||
target_arch:
|
target_arch:
|
||||||
description: "Architecture to build."
|
description: 'Architecture to build.'
|
||||||
options:
|
options:
|
||||||
- amd64
|
- amd64
|
||||||
- arm64
|
- arm64
|
||||||
default: amd64
|
default: amd64
|
||||||
OS:
|
OS:
|
||||||
description: "Base OS image name (e.g. alpine, redhat, ubuntu)."
|
description: 'Base OS image name (e.g. alpine, redhat, ubuntu).'
|
||||||
default: alpine
|
default: alpine
|
||||||
OS_VERSION:
|
OS_VERSION:
|
||||||
description: "OS version / image tag (e.g. 3.24, 9, jammy, noble)."
|
description: 'OS version / image tag (e.g. 3.24, 9, jammy, noble).'
|
||||||
default: "3.24"
|
default: '3.24'
|
||||||
R_VERSION:
|
R_VERSION:
|
||||||
description: "Primary R version under /opt/R."
|
description: 'Primary R version under /opt/R.'
|
||||||
options:
|
options:
|
||||||
- 4.5.3
|
- 4.5.3
|
||||||
- 4.4.3
|
- 4.4.3
|
||||||
|
|
@ -99,6 +99,11 @@ steps:
|
||||||
- ${ARCH}-binaries-r-dep-cache-${OS}-${OS_VERSION//./}:/mnt/cache
|
- ${ARCH}-binaries-r-dep-cache-${OS}-${OS_VERSION//./}:/mnt/cache
|
||||||
commands:
|
commands:
|
||||||
- git clone -q https://pat-s:$$REPO_RO_TOKEN@git.devxy.io/devxy/build-cran-binaries.git .
|
- git clone -q https://pat-s:$$REPO_RO_TOKEN@git.devxy.io/devxy/build-cran-binaries.git .
|
||||||
|
# Clear churny pkgcache metadata left by a prior crashed run (the "patched"
|
||||||
|
# repo mints a new hash per PACKAGES change -> unbounded pkgs-*.rds/patched-*).
|
||||||
|
# Keep pkg/ downloads and the stable CRAN/BioC/INLA repo dirs. Within-run
|
||||||
|
# growth is bounded separately by trim_pkgcache_metadata() in build-all.R.
|
||||||
|
- rm -rf /mnt/cache/pkgcache/R/pkgcache/_metadata/patched-* /mnt/cache/pkgcache/R/pkgcache/_metadata/pkgs-*.rds || true
|
||||||
- mkdir -p /mnt/cache/pkgcache /mnt/cache/R-pkgs /mnt/cache/ccache /mnt/cache/packages
|
- mkdir -p /mnt/cache/pkgcache /mnt/cache/R-pkgs /mnt/cache/ccache /mnt/cache/packages
|
||||||
- XVFB=$(command -v xwfb-run 2>/dev/null || command -v xvfb-run); XVFB_ARGS=""; if command -v xwfb-run >/dev/null 2>&1; then dnf install -y -q weston 2>/dev/null; XVFB_ARGS="-c weston"; fi
|
- XVFB=$(command -v xwfb-run 2>/dev/null || command -v xvfb-run); XVFB_ARGS=""; if command -v xwfb-run >/dev/null 2>&1; then dnf install -y -q weston 2>/dev/null; XVFB_ARGS="-c weston"; fi
|
||||||
- $XVFB $XVFB_ARGS -n $SPLIT_INDEX -- /opt/R/$R_VERSION/bin/Rscript local/build-all.R $SPLIT_INTO $SPLIT_INDEX $NCPUS 2>&1
|
- $XVFB $XVFB_ARGS -n $SPLIT_INDEX -- /opt/R/$R_VERSION/bin/Rscript local/build-all.R $SPLIT_INTO $SPLIT_INDEX $NCPUS 2>&1
|
||||||
|
|
@ -152,4 +157,4 @@ steps:
|
||||||
cpu: 1000m
|
cpu: 1000m
|
||||||
limits:
|
limits:
|
||||||
memory: 20Gi
|
memory: 20Gi
|
||||||
cpu: 2000m
|
cpu: 2000m
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue