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

[FR] Add Alpine as base Docker image flavor #40

Closed
ngosang opened this issue Jul 27, 2022 · 9 comments
Closed

[FR] Add Alpine as base Docker image flavor #40

ngosang opened this issue Jul 27, 2022 · 9 comments
Assignees

Comments

@ngosang
Copy link

ngosang commented Jul 27, 2022

Use Alpine as base Docker image. The main benefit is reduce the Docker image size.
Example => https://github.com/ngosang/urbackup-exporter/blob/master/DockerfileAlpine

@PhilipMay
Copy link
Owner

Good point. Thanks for the suggestion @ngosang .

I had deliberately chosen the slim debian, because I think that the image is virtually never used alone.
Docker usually runs other images. Since Debian Slim is also used in other images, it does not matter.
The base image is there more or less as it is. Then the size no longer plays a role.

What do you think?

Anyway. I could provide both.
A Debian Slim version and an Alpine version.

Do you want to contibute an Alpine version?

@ngosang
Copy link
Author

ngosang commented Jul 27, 2022

I just opened another issue. It's not working for me ATM.
In this repository you have the 2 Dockerfiles and the GitHub action to publish both images => https://github.com/ngosang/urbackup-exporter
It's another Prometheus exporter in Python so it should be copy&paste.

@ngosang ngosang changed the title [Feature request] Use Alpine as base Docker image [FR] Use Alpine as base Docker image Jul 27, 2022
@PhilipMay PhilipMay changed the title [FR] Use Alpine as base Docker image [FR] Add Alpine as base Docker image Jul 27, 2022
@PhilipMay PhilipMay changed the title [FR] Add Alpine as base Docker image [FR] Add Alpine as base Docker image flavor Jul 27, 2022
@PhilipMay
Copy link
Owner

Thanks for your link and "template" @ngosang

I added an Alpine flavor in Version "0.0.4rc1" - could you maybe test it please?

https://github.com/PhilipMay/smart-prom-next/pkgs/container/smart-prom-next/29988670?tag=0.0.4rc1-alpine

@PhilipMay
Copy link
Owner

@ngosang on my private bare metal docker installation the alpine image works...

@PhilipMay PhilipMay self-assigned this Jul 27, 2022
@ngosang
Copy link
Author

ngosang commented Jul 27, 2022

Tested. It works well but it's possible to reduce Docker' images size to half. You can pen another issue for that.

image

@PhilipMay
Copy link
Owner

Thanks for testing. Does that mean that I can also close #41 ?

@ngosang what do you mean by "You can pen another issue for that."

@ngosang
Copy link
Author

ngosang commented Jul 27, 2022

it's possible to reduce Docker' images size to half. (if you do some changes in the Dockerfiles to avoid caching files and reduce the number of layers)

You can open another issue for that.

@PhilipMay
Copy link
Owner

You can open another issue for that.

Ok - done in #45

@PhilipMay
Copy link
Owner

closing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants