feat(ci): OS/OS_VERSION manual dropdowns + restore lost crow fix (#97)
## Summary
Two changes:
1. **`OS`/`OS_VERSION` manual-run dropdowns** — give these form variables explicit `options:` lists (like `target_arch` and `R_VERSION`), so the manual-run form shows dropdowns instead of free-text, in both `build-all-versions.yaml` and `build-all-versions-install-deps.yaml`. Crow form variables are independent (no cascading), so the operator still has to pick a coherent `OS` + `OS_VERSION` combination (e.g. `redhat` + `9`, not `alpine` + `jammy`).
2. **Repairs `main`** — the crow fix from PR #96 (`bc2f6f1`) was lost when that PR was squashed (only the first commit was captured). As a result `main` currently carries the `OS: ${OS}` env vars that break Crow parsing (`unable to parse variable name`) and the unfixed `build-all.R`. This PR re-applies that fix: drop the env additions and derive `platform`/`arch` inside `build-all.R` from the container (bincraft codename → platform mapping + `Sys.info()` arch).
## Notes
- `OS_VERSION` options are quoted strings so tags like `8`/`9`/`10` aren't parsed as integers.
- Validated: both YAMLs parse, `build-all.R` parses.
Reviewed-on: #97
This commit is contained in:
parent
0f4330c05c
commit
83c761b736
2 changed files with 51 additions and 13 deletions
|
|
@ -10,10 +10,21 @@ variables:
|
|||
- arm64
|
||||
default: amd64
|
||||
OS:
|
||||
description: "Base OS image name (e.g. alpine, redhat, ubuntu)."
|
||||
description: "Base OS image name."
|
||||
options:
|
||||
- alpine
|
||||
- redhat
|
||||
- ubuntu
|
||||
default: alpine
|
||||
OS_VERSION:
|
||||
description: "OS version / image tag (e.g. 3.24, 9, jammy, noble)."
|
||||
description: "OS image tag. Must match OS (alpine: 3.24; redhat: 8/9/10; ubuntu: jammy/noble)."
|
||||
options:
|
||||
- "3.24"
|
||||
- "8"
|
||||
- "9"
|
||||
- "10"
|
||||
- "jammy"
|
||||
- "noble"
|
||||
default: "3.24"
|
||||
R_VERSION:
|
||||
description: "Primary R version under /opt/R."
|
||||
|
|
|
|||
|
|
@ -11,10 +11,21 @@ variables:
|
|||
- arm64
|
||||
default: amd64
|
||||
OS:
|
||||
description: "Base OS image name (e.g. alpine, redhat, ubuntu)."
|
||||
description: "Base OS image name."
|
||||
options:
|
||||
- alpine
|
||||
- redhat
|
||||
- ubuntu
|
||||
default: alpine
|
||||
OS_VERSION:
|
||||
description: "OS version / image tag (e.g. 3.24, 9, jammy, noble)."
|
||||
description: "OS image tag. Must match OS (alpine: 3.24; redhat: 8/9/10; ubuntu: jammy/noble)."
|
||||
options:
|
||||
- "3.24"
|
||||
- "8"
|
||||
- "9"
|
||||
- "10"
|
||||
- "jammy"
|
||||
- "noble"
|
||||
default: "3.24"
|
||||
R_VERSION:
|
||||
description: "Primary R version under /opt/R."
|
||||
|
|
@ -90,13 +101,6 @@ steps:
|
|||
from_secret: GITHUB_PAT
|
||||
# normal env vars
|
||||
GIT_USER: pat-s
|
||||
# Export the platform selectors as runtime env vars. They are otherwise
|
||||
# only available for ${...} interpolation (image/volume), so build-all.R's
|
||||
# `Sys.getenv("OS")/("OS_VERSION")/("ARCH")` would be empty and its
|
||||
# already-built dedup query would match platform "-" and skip nothing.
|
||||
OS: ${OS}
|
||||
OS_VERSION: ${OS_VERSION}
|
||||
ARCH: ${ARCH}
|
||||
# set the location of the 'pkgcache' cache dir which persists the R package dependencies needed to install the packages themselves
|
||||
R_PKG_CACHE_DIR: ${R_PKG_CACHE_DIR}
|
||||
R_LIBS_USER: /mnt/cache/R-pkgs
|
||||
|
|
|
|||
Loading…
Reference in a new issue