-
Notifications
You must be signed in to change notification settings - Fork 19
/
Dockerfile
52 lines (46 loc) · 1.1 KB
/
Dockerfile
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
49
50
51
52
FROM alpine:3.10.3
MAINTAINER Patrick Pötz <[email protected]>
# most of it is stolen from: pad92/docker-ansible-alpine
RUN echo "=== INSTALLING SYS DEPS" && \
apk update && \
apk add --no-cache \
ca-certificates \
git \
openssh-client \
openssl \
python3 \
rsync \
sshpass \
gettext && \
apk --update add --virtual \
builddeps \
python3-dev \
libffi-dev \
openssl-dev \
build-base && \
\
echo "=== INSTALLING PIP DEPS" && \
pip3 install --upgrade \
pip \
cffi && \
pip3 install \
ansible==2.8.5 \
botocore \
boto \
boto3 && \
\
echo "=== Cleanup this mess ===" \
apk upgrade && \
apk del builddeps && \
rm -rf /var/cache/apk/*
RUN mkdir -p /etc/ansible \
&& echo 'localhost' > /etc/ansible/hosts \
&& echo -e """\
\n\
Host *\n\
StrictHostKeyChecking no\n\
UserKnownHostsFile=/dev/null\n\
""" >> /etc/ssh/ssh_config
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]