Добавить memory policy для frontend build в builder и задокументировать override
This commit is contained in:
@@ -176,9 +176,32 @@ If frozen install fails, update dependencies intentionally in source control and
|
||||
- `PACKAGE_VERSION=0.1.6`
|
||||
- `BUILD_ID=prod-$(date -u +%Y%m%dT%H%M%SZ)`
|
||||
- `BUN_FLAVOR=auto|x64|x64-baseline`
|
||||
- `FRONTEND_NODE_OLD_SPACE_SIZE=2048` (default memory limit for frontend build step)
|
||||
- `TOOLCHAIN_DIR=/custom/path/.toolchain`
|
||||
- `VERIFY_TOOLCHAIN_CHECKSUMS=true`
|
||||
|
||||
## Frontend memory policy
|
||||
|
||||
Builder applies a safe default Node.js heap limit for frontend build inside [`bundle_ui()`](lib/package.sh):
|
||||
|
||||
```bash
|
||||
--max-old-space-size=2048
|
||||
```
|
||||
|
||||
Override options:
|
||||
|
||||
- adjust default value for this policy:
|
||||
|
||||
```bash
|
||||
FRONTEND_NODE_OLD_SPACE_SIZE=3072 ./tools/build/build.sh
|
||||
```
|
||||
|
||||
- or provide full custom Node options (if `--max-old-space-size` is already set there, builder will not append another one):
|
||||
|
||||
```bash
|
||||
NODE_OPTIONS="--max-old-space-size=3072" ./tools/build/build.sh
|
||||
```
|
||||
|
||||
## Диагностика
|
||||
|
||||
Проверить AVX2:
|
||||
|
||||
Reference in New Issue
Block a user