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

Introduce thin and full docker images #2090

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

tboerger
Copy link
Collaborator

@tboerger tboerger commented Jun 9, 2024

No description provided.

@fiftin
Copy link
Collaborator

fiftin commented Jun 10, 2024

@tboerger what reason to create one more image with cargo? I tried, cargo not required for installation of ansible, boto, etc. Lets remove it from the image and that's it.

@fiftin
Copy link
Collaborator

fiftin commented Jun 10, 2024

If needed we can create separate image based on semaphoreui/semaphore.

@tboerger
Copy link
Collaborator Author

Cargo is for sure required for cryptography and this is also some dependency of other packages installed within the image. As describe on chat the thin image stays with the same tag as before, just for giving more flexibility to customize the semaphore image there is the customize tag.

The customize tag starts as root user, which makes it possible to install alpine packages via packages.txt and it also starts with base-build and cargo for being able to install nearly any python dependency. Later on in the start process it's using su-exec to drop the privileges for running the semaphore process.

@fiftin
Copy link
Collaborator

fiftin commented Jun 12, 2024

I'm understood why cargo needed (for arm). But building already too long. Let's leave thin image and extend it with full image if required.

I planning to use this way for creating multiple images for terraform, pulumi, opentofu, etc.

@tboerger
Copy link
Collaborator Author

I'm currently experimenting with the installed tools a little bit to get a good image size. I would suggest to simply use the Alpine package for Ansible for the slim version and using pip maybe only within the custom tag as this will boost the container size.

In the end the user can choose one of the images depending on how much he wants to customize it.

@tboerger
Copy link
Collaborator Author

The current state WITH python-dev reaches 843MB. Without python-dev you are not able to install so many oython deps... Than we could directly drop the requirements.yml entirely from the slim image and preinstall a specific subset of python modules from Alpine packages only.

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

Successfully merging this pull request may close these issues.

None yet

2 participants