semaphore
semaphore copied to clipboard
installing python modules required by collections in semaphore docker container?
Just wondering how this is recommended?
Especially since pip isnt installed either. For example I need pywinrm for ansible.windows collection.
Same question here. I'm wondering if this is just an anti-pattern or if there's any trick to accomplish that. Need support for ansible-galaxy collection install hetzner.hcloud and the hcloud-python lib.
As a quick fix:
docker exec -it <container_id> sh
wget https://bootstrap.pypa.io/get-pip.py
python get-pip.py
python3 -m pip install ..
As a quick fix:
docker exec -it <container_id> sh
wget https://bootstrap.pypa.io/get-pip.py
python get-pip.py
python3 -m pip install ..
Thank you. thats a great solution. I am certain that would work for most and if that is the devs preferred method I suggest perhaps they install it by default as part of the docker container.
For me a solution didnt come fast enough so I abandoned the docker container and migrated it to an LXC container where I had more control to install my dependancies.
I think the clean way would be to build your own custom image from the semaphore image and use that image.
my dockerfile looks like this: FROM semaphoreui/semaphore:latest USER root RUN apk add --no-cache python3 py3-pip && pip3 install pyvmomi
Related to: https://github.com/ansible-semaphore/semaphore/pull/1498