-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1432 from grycap/devel
Devel
- Loading branch information
Showing
2 changed files
with
12 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,21 @@ | ||
# Dockerfile to create a container with the IM service | ||
FROM alpine:3.16 | ||
ARG BRANCH=devel | ||
FROM ubuntu:22.04 | ||
LABEL maintainer="Miguel Caballer <[email protected]>" | ||
LABEL version="1.13.0" | ||
LABEL description="Container image to run the IM service. (http://www.grycap.upv.es/im)" | ||
EXPOSE 8899 8800 | ||
|
||
# Update and install all the necessary packages | ||
RUN apk add --no-cache \ | ||
python3 \ | ||
py3-pip \ | ||
py3-mysqlclient \ | ||
py3-psutil \ | ||
openssh-client \ | ||
sshpass \ | ||
vim | ||
# Ensure system is up to date with mandatory python packages installed | ||
RUN apt-get update && apt-get install --no-install-recommends -y python3 python3-distutils openssh-client sshpass vim libmysqlclient21 python3-mysqldb && \ | ||
apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* && rm -rf ~/.cache/ | ||
|
||
# Install IM | ||
RUN pip3 install msrest \ | ||
msrestazure \ | ||
azure-common \ | ||
azure-mgmt-storage \ | ||
azure-mgmt-compute \ | ||
azure-mgmt-network \ | ||
azure-mgmt-resource \ | ||
azure-mgmt-dns \ | ||
azure-identity==1.8.0 | ||
|
||
RUN pip3 install pyOpenSSL \ | ||
cheroot \ | ||
xmltodict \ | ||
pymongo | ||
|
||
RUN pip3 install ansible==6.4.0 | ||
|
||
RUN apk add --no-cache git &&\ | ||
pip3 install git+https://github.com/grycap/im@$BRANCH &&\ | ||
apk del git | ||
RUN apt-get update && apt-get install --no-install-recommends -y python3-setuptools python3-pip git && \ | ||
pip3 install msrest msrestazure azure-common azure-mgmt-storage azure-mgmt-compute azure-mgmt-network azure-mgmt-resource azure-mgmt-dns azure-identity==1.8.0 && \ | ||
pip3 install pyOpenSSL cheroot xmltodict pymongo ansible==6.4.0&& \ | ||
pip3 install git+https://github.com/grycap/im@$BRANCH && \ | ||
apt-get purge -y python3-pip git && \ | ||
apt-get autoremove -y && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* && rm -rf ~/.cache/ | ||
|
||
# Set the VM_NUM_USE_CTXT_DIST to 3 for the tests | ||
RUN sed -i -e 's/VM_NUM_USE_CTXT_DIST = 30/VM_NUM_USE_CTXT_DIST = 3/g' /etc/im/im.cfg | ||
|
@@ -48,4 +27,4 @@ COPY ansible.cfg /etc/ansible/ansible.cfg | |
COPY endpoints.json /usr/local/lib/python3.8/dist-packages/boto/endpoints.json | ||
|
||
# Start IM service | ||
CMD im_service.py | ||
CMD im_service.py |