-
Notifications
You must be signed in to change notification settings - Fork 10
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
Use multi-stage builds to unzip and copy jars #118
base: main
Are you sure you want to change the base?
Conversation
Delta Summary - Kotlin Code Coverage
|
9c21d00
to
39ebe00
Compare
39ebe00
to
509c849
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #118 +/- ##
============================================
- Coverage 70.36% 70.35% -0.02%
Complexity 1040 1040
============================================
Files 282 282
Lines 11316 11316
Branches 1083 1083
============================================
- Hits 7963 7961 -2
Misses 2886 2886
- Partials 467 469 +2
*This pull request uses carry forward flags. Click here to find out more. |
d472ac4
to
da905b6
Compare
|
||
RUN case $(uname -m) in \ | ||
x86_64) \ | ||
rm -rf /libs/coordinator/lib/unpacked-blob-compressor/darwin-**; \ |
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.
Can this be moved out from the switch case here? Seems they would be removed regardless of the case, or can we use a local label to replace the the switch case to avoid repeated commands? sth like:
...
rm -rf /libs/coordinator/lib/unpacked-blob-compressor/linux-$MACHINE_TYPE/; \
...
rm -rf /libs/coordinator/lib/unpacked-blob-shnarf-calculator/linux-$MACHINE_TYPE/;
COPY --from=zip ./coordinator.zip /src | ||
|
||
RUN unzip /src/coordinator.zip -d /libs | ||
|
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.
I'd suggest to add the below line here to avoid the repeated prefix in paths:
WORKDIR /libs/coordinator/lib/
This PR implements issue(s) #
Multi stage reduces size of image by 110MB.
Removes unnecessary libs depending on architecture.
Checklist