Commit a03c1e66 authored by xuchentao's avatar xuchentao

fix: support Node.js 20 deployment

parent 8a0972f4
Pipeline #411 failed with stages
in 44 seconds
This diff is collapsed.
......@@ -3,8 +3,11 @@
"type": "module",
"version": "1.0.0",
"private": true,
"engines": {
"node": ">=20.20.0 <21"
},
"scripts": {
"dev": "node --env-file=.env ./node_modules/astro/bin/astro.mjs dev",
"dev": "node --env-file=.env ./node_modules/astro/astro.js dev",
"build": "node scripts/build-site.mjs",
"build:inside-lock": "node scripts/build-site.mjs --inside-lock",
"build:astro": "astro check && astro build",
......@@ -15,9 +18,9 @@
"serve": "npm run build && npm start"
},
"dependencies": {
"@astrojs/node": "^11.0.2",
"@astrojs/node": "9.5.5",
"@astrojs/sitemap": "^3.7.3",
"astro": "^7.1.3",
"astro": "5.18.2",
"gray-matter": "^4.0.3",
"marked": "^14.1.4"
},
......
......@@ -11,7 +11,7 @@ const DEFAULT_LOCK = process.env.CMS_DATA_DIR
: path.join(RUNTIME_DIR, "site-build.lock");
const LOCK_FILE = path.resolve(process.env.CMS_BUILD_LOCK || DEFAULT_LOCK);
const RECOVERY_LOCK_FILE = `${LOCK_FILE}.recovery`;
const ASTRO_BIN = path.join(ROOT, "node_modules", "astro", "bin", "astro.mjs");
const ASTRO_BIN = path.join(ROOT, "node_modules", "astro", "astro.js");
const DIST_DIR = path.join(ROOT, "dist");
const MAX_LOG_LENGTH = 2 * 1024 * 1024;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment