diff --git a/Dockerfile b/Dockerfile index 766c258..3c3652a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -52,7 +52,8 @@ EXPOSE ${PORT} STOPSIGNAL SIGINT ENTRYPOINT [ "bash", "docker-entrypoint.sh" ] -RUN yarn build:nostatic +RUN yarn remove:files +RUN yarn build:typescript COPY static /app/dist/static HEALTHCHECK --interval=30s --timeout=30s --start-period=5s \ diff --git a/package.json b/package.json index aafc077..a5a7209 100644 --- a/package.json +++ b/package.json @@ -89,10 +89,9 @@ "copy:files": "copyFiles -u 1 static/**/* dist/static", "remove:files": "rimraf dist", "test:unit": "jest --config config/jest.config.js", - "build:nostatic": "yarn remove:files && tsc --project ./", - "build:typescript": "tsc --project tsconfig.json && tscpaths -p tsconfig.json -s ./src -o ./dist", + "build:typescript": "tsc --project tsconfig.json", "build": "yarn remove:files && yarn copy:files && yarn build:typescript", - "start": "node -r tsconfig-paths/register -r ts-node ./dist/src/server.js", + "start": "TS_NODE_BASEURL=./dist node -r tsconfig-paths/register ./dist/src/server.js", "dev": "nodemon", "lint": "eslint src --fix", "types:check": "tsc --noEmit --pretty",