Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added active waiting for cmake-js (Text file busy) race condiion #350

Merged
merged 1 commit into from
Nov 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions QuoteVerification/QuoteVerificationService/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ COPY src /qvs/src
COPY configuration-default /qvs/configuration-default
# build QVS
RUN echo 'cmake_QVL_PATH=/qvl/Build/Release/dist' >> /qvs/src/.npmrc # workaround for npm 9+ https://github.com/npm/cli/issues/5852
RUN cd /qvs/src && npm install
# copy compiled bianries
RUN cd /qvs/src && npm install && npm run wait-for-cmake-js && npm run build-native # workaournd for Text file busy race condition https://github.com/nodejs/docker-node/issues/1918
# copy compiled binaries
RUN mkdir -p /qvs/native/lib/ \
&& cp /qvl/Build/Release/dist/lib/*.so /qvs/native/lib/ \
&& cp /qvs/src/qvl/cmake-build-release/Release/*.node /qvs/native/ \
Expand Down
3 changes: 2 additions & 1 deletion QuoteVerification/QuoteVerificationService/src/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
{
"name": "quoteverificationservice",
"scripts": {
"install": "cmake-js build -d qvl/ -O qvl/cmake-build-release",
"wait-for-cmake-js": "timeout 10s bash -c 'until cmake-js --version; do sleep 1; done'",
"build-native": "cmake-js build -d qvl/ -O qvl/cmake-build-release",
"swagger": "node swagger.js"
},
"version": "1.0.0",
Expand Down