coder / coder/registry

mux: bootstrap the Node.js runtime under the module root instead of ~/.local/share/coder-mux

Open
#1,100 2 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
HCL
Stars
79
Forks
161
Avg merge
1d 10h
Merged PRs (30d)
38

Description

Follow-up from https://github.com/coder/registry/pull/1095 (review body finding on `scripts/install.sh.tftpl:27`).

When the workspace image has no `node`, `ensure_node` bootstraps a pinned Node.js runtime into `$HOME/.local/share/coder-mux/node-v-linux-`, and `start.sh.tftpl` looks it up at the same path. #1095 established `$HOME/.coder-modules/coder/mux` as the module root for the install, logs and scripts, but left the runtime at this pre-existing ad-hoc path, so troubleshooting and cleanup are split across two locations (AGENTS.md: module-managed runtime data must live under the per-module root).

Proposed change: bootstrap into `${INSTALL_PREFIX}/node/node-v-linux-` (or a sibling directory under the module root), update the start script's `use_bootstrapped_node` lookup, the `CODER_SCRIPT_BIN_DIR/node` symlink target and the README note. Workspaces that already have a runtime under `~/.local/share/coder-mux` would download it once more on the next start; alternatively check the old path and move it.

> Xum acted on behalf of @ibetitsmike when filing this issue.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.