fix: set rootDir to src in tsconfig.build.json for consistent output
Some checks failed
Deploy API Server / build-and-deploy (push) Failing after 18s
Some checks failed
Deploy API Server / build-and-deploy (push) Failing after 18s
The NestJS build was outputting to dist/src/main.js instead of dist/main.js due to TypeScript's automatic rootDir calculation. Explicit rootDir: "src" ensures the output is always at dist/main.js. Also remove the test-run debugging step from CI. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
parent
61d1f3885c
commit
2b72d94a24
@ -79,11 +79,6 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
cd /opt/zhixi/backend && npx prisma generate
|
cd /opt/zhixi/backend && npx prisma generate
|
||||||
|
|
||||||
- name: Test-run API to capture startup errors
|
|
||||||
run: |
|
|
||||||
cd /opt/zhixi/backend
|
|
||||||
timeout 5 node dist/main.js 2>&1 || true
|
|
||||||
|
|
||||||
- name: Restart API service
|
- name: Restart API service
|
||||||
run: |
|
run: |
|
||||||
sudo systemctl restart zhixi-api
|
sudo systemctl restart zhixi-api
|
||||||
|
|||||||
@ -1,4 +1,7 @@
|
|||||||
{
|
{
|
||||||
"extends": "./tsconfig.json",
|
"extends": "./tsconfig.json",
|
||||||
|
"compilerOptions": {
|
||||||
|
"rootDir": "src"
|
||||||
|
},
|
||||||
"exclude": ["node_modules", "test", "dist", "**/*spec.ts"]
|
"exclude": ["node_modules", "test", "dist", "**/*spec.ts"]
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user