-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
58 lines (52 loc) · 1.5 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
53
54
55
56
57
58
FROM ubuntu:20.04
RUN apt-get update \
&& export DEBIAN_FRONTEND=noninteractive \
&& apt-get -y install --no-install-recommends \
build-essential \
libssl-dev \
libffi-dev \
python-dev \
python3-pip \
git \
wget \
curl \
tree \
gawk \
jq \
iputils-ping \
unzip \
ssh \
sshpass
# Install python packages for ansible
RUN pip3 install \
paramiko \
jmespath \
pyvmomi \
jsonpath-ng \
requests_toolbelt \
requests
# Install ansible
ENV ANSIBLE_VERSION=2.10.7
RUN pip3 install ansible==${ANSIBLE_VERSION}
# Install ansible collection for cisco datacenter
RUN ansible-galaxy collection install \
cisco.aci \
cisco.dcnm \
cisco.intersight \
cisco.ios \
cisco.iosxr \
cisco.mso \
cisco.nso \
cisco.nxos \
cisco.ucs \
community.general
ENV TERRAFORM_VERSION=1.4.4
RUN curl -sSL -o /tmp/terraform.zip https://releases.hashicorp.com/terraform/${TERRAFORM_VERSION}/terraform_${TERRAFORM_VERSION}_linux_amd64.zip 2>&1 \
&& unzip -d /usr/bin /tmp/terraform.zip \
&& chmod +x /usr/bin/terraform \
&& mkdir -p /root/.terraform.cache/plugin-cache \
&& rm -f /tmp/terraform.zip \
&& terraform -install-autocomplete
# To avoid error - "SSL: DH_KEY_TOO_SMALL] dh key too small"
RUN mv /etc/ssl/openssl.cnf /etc/ssl/openssl.cnf.bak
COPY openssl.cnf /etc/ssl/openssl.cnf