docs: update Node.js to 24 LTS, switch to nvm + corepack
- Use nvm v0.40.4 + nvm install 24 (24.14.0 LTS) instead of nodesource - Use corepack enable pnpm instead of npm install -g pnpm - Add symlink step: ln -sf \$(nvm which current) /usr/local/bin/node so systemd service can reference a stable path - Update ExecStart in innercontext-node.service: /usr/bin → /usr/local/bin - Update Node.js version references in README.md (22 → 24 LTS) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
3c1dcbeb06
commit
a2500a919b
3 changed files with 13 additions and 6 deletions
|
|
@ -33,7 +33,7 @@ API docs available at `http://localhost:8000/docs`.
|
||||||
|
|
||||||
## Frontend quick start
|
## Frontend quick start
|
||||||
|
|
||||||
**Requirements:** Node.js 22+, [pnpm](https://pnpm.io/)
|
**Requirements:** Node.js 24 LTS+, [pnpm](https://pnpm.io/)
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cd frontend
|
cd frontend
|
||||||
|
|
|
||||||
|
|
@ -64,12 +64,19 @@ curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||||
source $HOME/.local/bin/env # or re-login
|
source $HOME/.local/bin/env # or re-login
|
||||||
```
|
```
|
||||||
|
|
||||||
### Node.js 22 + pnpm
|
### Node.js 24 LTS + pnpm
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
curl -fsSL https://deb.nodesource.com/setup_22.x | bash -
|
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.4/install.sh | bash
|
||||||
apt install -y nodejs
|
. "$HOME/.nvm/nvm.sh"
|
||||||
npm install -g pnpm
|
nvm install 24
|
||||||
|
corepack enable pnpm
|
||||||
|
```
|
||||||
|
|
||||||
|
Create a stable symlink so systemd can find `node` at a fixed path:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
ln -sf "$(nvm which current)" /usr/local/bin/node
|
||||||
```
|
```
|
||||||
|
|
||||||
### Application user
|
### Application user
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@ WorkingDirectory=/opt/innercontext/frontend
|
||||||
Environment=PORT=3000
|
Environment=PORT=3000
|
||||||
Environment=HOST=127.0.0.1
|
Environment=HOST=127.0.0.1
|
||||||
EnvironmentFile=/opt/innercontext/frontend/.env.production
|
EnvironmentFile=/opt/innercontext/frontend/.env.production
|
||||||
ExecStart=/usr/bin/node /opt/innercontext/frontend/build/index.js
|
ExecStart=/usr/local/bin/node /opt/innercontext/frontend/build/index.js
|
||||||
Restart=on-failure
|
Restart=on-failure
|
||||||
RestartSec=5
|
RestartSec=5
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue