fix: revert rootDir, instead normalize dist path in CI build step
Some checks failed
Deploy API Server / build-and-deploy (push) Failing after 33s
Some checks failed
Deploy API Server / build-and-deploy (push) Failing after 33s
The rootDir approach caused cascading TypeScript compilation issues. Instead, the CI now detects whether nest build outputs to dist/src/main.js and moves it to dist/main.js automatically. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
parent
2c530ef73a
commit
fbe2e96381
@ -29,6 +29,13 @@ jobs:
|
||||
cd /tmp/api-server
|
||||
npx prisma generate
|
||||
npm run build
|
||||
# Normalize output: ensure main.js is at dist/main.js
|
||||
if [ ! -f dist/main.js ] && [ -f dist/src/main.js ]; then
|
||||
echo "[build] Moving dist/src/* to dist/"
|
||||
mv dist/src/* dist/
|
||||
rm -rf dist/src
|
||||
fi
|
||||
ls -la dist/main.js
|
||||
|
||||
- name: Ensure infrastructure is ready
|
||||
run: |
|
||||
|
||||
@ -1,7 +1,4 @@
|
||||
{
|
||||
"extends": "./tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"rootDir": "src"
|
||||
},
|
||||
"exclude": ["node_modules", "test", "dist", "prisma", "rag-worker", "**/*spec.ts"]
|
||||
"exclude": ["node_modules", "test", "dist", "**/*spec.ts"]
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user