-
-
Notifications
You must be signed in to change notification settings - Fork 239
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
refactor: optimize dockerfile for AsyncAPI generator setup #1286
Conversation
|
- Moved the ARG instruction inside the build stage where it is used. - Surrounded $ASYNCAPI_GENERATOR_VERSION with double quotes to prevent word splitting and globbing issues. - Improved maintainability and reliability by ensuring proper variable handling.
This reverts commit 0fc7853.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please update your PR to address only the issue mentioned in sonar issue that you linked
This reverts commit c95b953.
apps/generator/Dockerfile
Outdated
FROM node:18-alpine | ||
|
||
ARG ASYNCAPI_GENERATOR_VERSION="1.10.9" # Include ARG in the build stage and surround it with double quotes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pls. remove these unwanted comments
apps/generator/Dockerfile
Outdated
# Installing latest released npm package | ||
RUN npm install -g @asyncapi/generator@$ASYNCAPI_GENERATOR_VERSION | ||
RUN apk --update add --no-cache git chromium && \ | ||
npm install -g @asyncapi/generator@"$ASYNCAPI_GENERATOR_VERSION" && \ # Surround variable with double quotes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From here also, pls. remove extra commnets
Quality Gate passedIssues Measures |
Description
-I tried to solve this issue