Skip to content

Commit

Permalink
fix: Make LM to run indentically on Mac and in Docker
Browse files Browse the repository at this point in the history
  • Loading branch information
fmarek-kindred committed May 27, 2024
1 parent 4a07a6c commit d0205aa
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lock-manager/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@
"scripts": {
"clean": "rm -rf dist",
"build": "npm run clean && npx tsc && npm run copy.openapi.spec",
"copy.openapi.spec": "copyfiles src/web-api/**/open-api-schema*.yml dist/",
"test": "npm run build && c8 --reporter=html --reporter=text mocha --timeout 10000 --recursive dist/test/ --loader=esmock",
"copy.openapi.spec": "copyfiles -f src/web-api/v1/open-api-schema*.yml dist/web-api/v1/",
"test": "npm run clean && npx tsc -p tsconfig-tests.json && copyfiles src/web-api/*/open-api-schema*.yml dist/ && c8 --reporter=html --reporter=text mocha --timeout 10000 --recursive dist/test/ --loader=esmock",
"watch": "npx tsc --watch",
"dev.start": "set -o allexport; source .env ; set +o allexport; npm run build && npm run start",
"dev.build-image": "source .env; docker build -t $REGISTRY_URL/$SERVICE_NAME:$IMAGE_TAG .",
Expand Down
2 changes: 1 addition & 1 deletion lock-manager/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const main = async () => {

const _apiRoutes = new ApiRoutes(app, db)
// const oasFilePath = new URL(" ", import.meta.url).pathname
const oasFilePath = "dist/src/web-api/v1/open-api-schema-v1.yml"
const oasFilePath = "dist/web-api/v1/open-api-schema-v1.yml"
try {
await fs.promises.access(oasFilePath, fs.constants.R_OK)
} catch (e) {
Expand Down
18 changes: 18 additions & 0 deletions lock-manager/tsconfig-tests.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"compilerOptions": {
"module": "node16",
"esModuleInterop": true,
"allowArbitraryExtensions": true,
"declaration": true,
"target": "ES2022",
"moduleResolution": "node16",
"sourceMap": true,
"outDir": "dist",
},
"include": ["src/**/**/*.ts", "test/**/*.ts", "test/**/**/*.ts"],
"exclude": [
"build",
"dist",
"node_modules",
]
}
2 changes: 1 addition & 1 deletion lock-manager/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"sourceMap": true,
"outDir": "dist"
},
"include": ["src/**/**/*.ts", "test/**/*.ts", "test/**/**/*.ts"],
"include": ["src/**/**/*.ts"],
"exclude": [
"build",
"dist",
Expand Down

0 comments on commit d0205aa

Please sign in to comment.