blob: b9a2c28f9f035bf96dc03f93f49672a0b4d8036c [file] [log] [blame]
Alexa5e33462021-06-10 19:01:07 -05001FROM ubuntu:20.04
2
3MAINTAINER Alex Savatieiev (a.savex@gmail.com)
4
Alex73b792d2021-06-11 17:46:14 -05005ADD ./si-tests.tgz /opt/si-tests/
6WORKDIR /opt
Alexa5e33462021-06-10 19:01:07 -05007RUN apt-get update && \
8 apt-get install -y make gcc g++ git libaio-dev libaio1 zlib1g-dev && \
9 git clone --depth 1 --branch fio-3.26 https://github.com/axboe/fio.git && \
Alex73b792d2021-06-11 17:46:14 -050010 cd /opt/fio && \
Alexa5e33462021-06-10 19:01:07 -050011 ./configure && \
12 make && \
13 make install && \
Alex73b792d2021-06-11 17:46:14 -050014 cd /opt && \
Alex17e4a592021-07-13 15:59:33 -050015 rm -rf /opt/fio
16
17RUN export TZ="America/Chicago" && \
Alexa5e33462021-06-10 19:01:07 -050018 ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone && \
Alexf59c7392022-04-18 19:10:14 -050019 apt-get install -y python3-pip python3-venv vim git iperf3 mtr htop iputils-ping traceroute tcpdump wget iproute2 curl screen qemu-utils
Alex17e4a592021-07-13 15:59:33 -050020
Alex83075ac2022-02-16 13:39:50 -060021RUN pip3 install --no-cache-dir python-openstackclient python-neutronclient python-heatclient pyghmi python-octaviaclient tempestparser python-ironicclient aodhclient gnocchiclient python-barbicanclient python-glanceclient
Alex17e4a592021-07-13 15:59:33 -050022
23RUN git clone https://gerrit.mcp.mirantis.com/mcp/cvp-configuration /opt/res-files && \
Alex73b792d2021-06-11 17:46:14 -050024 git clone http://gerrit.mcp.mirantis.com/mcp/cfg-checker /opt/cfg-checker && \
25 cd /opt/cfg-checker && \
26 python3 -m venv .checkervenv && \
27 . .checkervenv/bin/activate && \
28 pip3 install --no-cache-dir -r requirements.txt && \
29 python3 setup.py develop && \
30 deactivate && \
Alexa5e33462021-06-10 19:01:07 -050031 mkdir /opt/cmp-check && cd /opt/cmp-check && \
32 cp /opt/res-files/scripts/prepare.sh ./ && \
33 cp /opt/res-files/scripts/cmp_check.sh ./ && \
Alex73b792d2021-06-11 17:46:14 -050034 cp /opt/res-files/cleanup.sh ./ && \
Alex73b792d2021-06-11 17:46:14 -050035 rm -rf /opt/res-files/.git && \
36 rm -rf /opt/cfg-checker/.git
Alexa5e33462021-06-10 19:01:07 -050037
Alex17e4a592021-07-13 15:59:33 -050038RUN cd /opt/si-tests/ && \
39 python3 -m venv .sivenv && \
40 . .sivenv/bin/activate && \
41 pip3 install --no-cache-dir -r si_tests/requirements.txt && \
42 deactivate && \
43 cd /opt
44
45RUN mkdir /opt/packages/ && \
46 cd /opt/packages && \
47 apt-get download $(apt-cache depends --recurse --no-recommends --no-suggests --no-conflicts --no-breaks --no-replaces --no-enhances iperf3 | grep "^\w" | sort -u) || true
48
Alexf2f657e2021-06-14 19:44:05 -050049RUN curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" && \
50 install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl && \
51 rm kubectl
52
Alexa5e33462021-06-10 19:01:07 -050053ENTRYPOINT ["sleep infinite"]
54