-
Notifications
You must be signed in to change notification settings - Fork 9
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
Docker image tweaks #230
Docker image tweaks #230
Conversation
f72eeb6
to
8411b1b
Compare
8411b1b
to
845c1e4
Compare
@@ -11,8 +11,8 @@ LABEL build-date-iso8601="${build_date}" | |||
|
|||
WORKDIR /root | |||
|
|||
COPY ${tar_path}/${tar_name} . |
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.
~170kB; but perhaps more imortant it looked weird to just have that tar left in there
@@ -11,8 +11,8 @@ LABEL build-date-iso8601="${build_date}" | |||
|
|||
WORKDIR /root | |||
|
|||
COPY ${tar_path}/${tar_name} . |
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.
~170kB; but perhaps more imortant it looked weird to just have that tar left in there
@@ -11,8 +11,8 @@ LABEL build-date-iso8601="${build_date}" | |||
|
|||
WORKDIR /root | |||
|
|||
COPY ${tar_path}/${tar_name} . |
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.
~170kB; but perhaps more imortant it looked weird to just have that tar left in there
@@ -11,8 +11,8 @@ LABEL build-date-iso8601="${build_date}" | |||
|
|||
WORKDIR /root | |||
|
|||
COPY ${tar_path}/${tar_name} . |
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.
~170kB; but perhaps more imortant it looked weird to just have that tar left in there
@@ -11,8 +11,8 @@ LABEL build-date-iso8601="${build_date}" | |||
|
|||
WORKDIR /root | |||
|
|||
COPY ${tar_path}/${tar_name} . |
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.
~170kB; but perhaps more imortant it looked weird to just have that tar left in there
@@ -11,8 +11,8 @@ LABEL build-date-iso8601="${build_date}" | |||
|
|||
WORKDIR /root | |||
|
|||
COPY ${tar_path}/${tar_name} . | |||
RUN ["pip", "install", "${tar_name}[full]"] |
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.
--no-cache-dir saves ~6MB
@@ -1,4 +1,4 @@ | |||
FROM python:${python_version}-slim as base | |||
FROM python:${python_version}-alpine as base |
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.
suprisingly enough, alpine switch "just works"; seems all binary dependencies do have musl wheel
@@ -1,4 +1,4 @@ | |||
FROM python:${python_version}-slim as base | |||
FROM python:${python_version}-alpine as base |
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.
suprisingly enough, alpine switch "just works"; seems all binary dependencies do have musl wheel
@@ -1,4 +1,4 @@ | |||
FROM python:${python_version}-slim as base | |||
FROM python:${python_version}-alpine as base |
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.
using builder
stage did not help save any disk space and was troublesome to get working - you have to be really careful what you want to copy, which makes Dockerfile significantly more complex.
We probably could do our custom python-base imagine, but I don't see that paying off as we don't even know how many MBs we can save that way.
If we ever start using standalone
binary in these images instead, we are likely to see better results than optimizing python install.
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.
ok but the builder
stage wasn't there when you started working on the thing, right?
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.
there was no builder stage
closed as alpine may degrade performance (unconfirmed) |
No description provided.