-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile.artifact
More file actions
48 lines (37 loc) · 1.25 KB
/
Dockerfile.artifact
File metadata and controls
48 lines (37 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Dockerfile for Python, Go and Ansible with the deployment engine, MongoDB in a parallel container.
# WIP = work in progress
# Artifact - executable + dependencies
FROM alpine:3.8
ENV BUILD_PACKAGES \
openssh-client \
sshpass \
git \
ansible
# Upgrading apk and system
RUN apk update && apk upgrade
# Adding runtime packages
RUN apk add --no-cache ${BUILD_PACKAGES}
# Cleaning up
RUN rm -rf /var/cache/apk/*
# Adding hosts for convenience
RUN mkdir -p /etc/ansible /ansible
RUN echo "[local]" >> /etc/ansible/hosts
RUN echo "localhost" >> /etc/ansible/hosts
ENV ANSIBLE_GATHERING smart
ENV ANSIBLE_HOST_KEY_CHECKING false
ENV ANSIBLE_RETRY_FILES_ENABLED false
# For unknown reasons ansible might find a host unreachable but it can be reached.
ENV ANSIBLE_SSH_RETRIES 10
ENV ANSIBLE_SSH_PIPELINING True
COPY deployment-engine /usr/bin/deployment-engine
RUN mkdir /root/deployment-engine
WORKDIR /root/deployment-engine
COPY provision/ansible/kubernetes kubernetes
COPY provision/ansible/common common
COPY ditas/scripts ditas
COPY docker/config.properties .
RUN git clone https://github.com/DITAS-Project/VDC-Shared-Config.git
EXPOSE 8080
#Trying to run the app when the container starts
RUN ["chmod", "+x", "/usr/bin/deployment-engine"]
CMD ["deployment-engine"]