ci(forgejo): install the .nvmrc Node before npm on the Linux runner
Some checks failed
ci / 정본·보안·린트·타입·테스트 (push) Failing after 59s
ci / 워크스페이스 빌드 검증 (push) Has been skipped
ci / 모바일 린트·타입·Jest (push) Successful in 41s
ci / Supabase Edge Functions + Cloudflare Worker (push) Successful in 21s
ci / .NET API 서버 테스트 (push) Successful in 16s
deploy-site / deploy (push) Successful in 21s
Some checks failed
ci / 정본·보안·린트·타입·테스트 (push) Failing after 59s
ci / 워크스페이스 빌드 검증 (push) Has been skipped
ci / 모바일 린트·타입·Jest (push) Successful in 41s
ci / Supabase Edge Functions + Cloudflare Worker (push) Successful in 21s
ci / .NET API 서버 테스트 (push) Successful in 16s
deploy-site / deploy (push) Successful in 21s
The first real Forgejo CI run failed because the linux-builder runner ships Node 18.19: scripts using import.meta.dirname threw, and its older npm reported the mobile lock as out of sync with the file: dependency on packages/core (the lock is in sync under Node 24's npm). bootstrap-linux-toolchain.sh gains a checksum-verified `node` mode (24.19.0, the .nvmrc version); ci.yml (quality, build-validation, mobile-quality) and deploy-site.yml add it to GITHUB_PATH before npm runs.
This commit is contained in:
parent
eedd127ea7
commit
b8a09c0333
3 changed files with 49 additions and 3 deletions
|
|
@ -8,7 +8,7 @@ set -euo pipefail
|
|||
|
||||
mode="${1:-}"
|
||||
if [[ -z "$mode" ]]; then
|
||||
echo 'bootstrap-linux-toolchain: mode is required (dotnet|deno|android)' >&2
|
||||
echo 'bootstrap-linux-toolchain: mode is required (node|dotnet|deno|android)' >&2
|
||||
return 64 2>/dev/null || exit 64
|
||||
fi
|
||||
|
||||
|
|
@ -32,6 +32,20 @@ download_verified() {
|
|||
esac
|
||||
}
|
||||
|
||||
# 러너 기본 node(Forgejo linux-builder는 18.x)는 .nvmrc(24.19.0)보다 낮다.
|
||||
bootstrap_node() {
|
||||
local node_root="$tools_root/node-v24.19.0-linux-x64"
|
||||
if [[ ! -x "$node_root/bin/node" ]]; then
|
||||
local archive
|
||||
archive="$(mktemp "${TMPDIR:-/tmp}/d3ro-node.XXXXXX.tar.gz")"
|
||||
download_verified 'https://nodejs.org/dist/v24.19.0/node-v24.19.0-linux-x64.tar.gz' 'f625d97cd707df4ff96254916fbc5ff014f09c09effe5a1e0ca8f6d41a8789d4' "$archive"
|
||||
tar --extract --gzip --file "$archive" --directory "$tools_root"
|
||||
rm -f "$archive"
|
||||
fi
|
||||
export PATH="$node_root/bin:$PATH"
|
||||
[[ "$(node --version)" == "v$(cat .nvmrc)" ]]
|
||||
}
|
||||
|
||||
bootstrap_dotnet() {
|
||||
export DOTNET_ROOT="$tools_root/dotnet-sdk-10.0.302"
|
||||
if [[ ! -x "$DOTNET_ROOT/dotnet" ]]; then
|
||||
|
|
@ -125,6 +139,7 @@ bootstrap_android() {
|
|||
}
|
||||
|
||||
case "$mode" in
|
||||
node) bootstrap_node ;;
|
||||
dotnet) bootstrap_dotnet ;;
|
||||
deno) bootstrap_deno ;;
|
||||
android) bootstrap_android ;;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue