1 FROM opnfv/functest-tempest
4 ARG OPENSTACK_TAG=master
5 ARG REFSTACK_TARGET=2018.02
9 ARG NEUTRON_RALLY_TAG=master
11 RUN apk --no-cache add --virtual .build-deps --update \
12 python-dev build-base linux-headers libffi-dev \
13 openssl-dev libjpeg-turbo-dev && \
14 wget -q -O- https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt?h=$OPENSTACK_TAG | \
15 sed -E s/^tempest==+.*$/-e\ git+https:\\/\\/git.openstack.org\\/openstack\\/tempest#egg=tempest/ \
16 > upper-constraints.txt && \
17 wget -q -O- https://git.opnfv.org/functest/plain/upper-constraints.txt?h=$BRANCH | \
18 sed -E /#egg=functest/d > upper-constraints.opnfv.txt && \
19 git init /src/patrole && \
21 git fetch --tags https://git.openstack.org/openstack/patrole.git $PATROLE_TAG && \
22 git checkout FETCH_HEAD) && \
23 update-requirements -s --source /src/openstack-requirements /src/patrole/ && \
24 git init /src/neutron-tempest-plugin && \
25 (cd /src/neutron-tempest-plugin && \
26 git fetch --tags https://git.openstack.org/openstack/neutron-tempest-plugin.git $NEUTRON_TAG && \
27 git checkout FETCH_HEAD) && \
28 update-requirements -s --source /src/openstack-requirements /src/neutron-tempest-plugin && \
29 git init /src/barbican-tempest-plugin && \
30 (cd /src/barbican-tempest-plugin && \
31 git fetch --tags https://git.openstack.org/openstack/barbican-tempest-plugin.git $BARBICAN_TAG && \
32 git checkout FETCH_HEAD) && \
33 update-requirements -s --source /src/openstack-requirements /src/barbican-tempest-plugin/ && \
34 pip install --no-cache-dir --src /src -cupper-constraints.txt -cupper-constraints.opnfv.txt \
35 /src/patrole /src/barbican-tempest-plugin /src/neutron-tempest-plugin \
36 networking-bgpvpn networking-sfc && \
37 rm -r upper-constraints.txt upper-constraints.opnfv.txt \
38 /src/patrole /src/barbican-tempest-plugin /src/neutron-tempest-plugin && \
39 mkdir -p /home/opnfv/functest/data/refstack && \
40 wget "https://refstack.openstack.org/api/v1/guidelines/${REFSTACK_TARGET}/tests?target=compute&type=required&alias=true&flag=false" \
41 -O /home/opnfv/functest/data/refstack/defcore.txt && \
42 mkdir -p /etc/neutron /etc/glance && \
43 wget -q -O /etc/neutron/policy.json https://git.openstack.org/cgit/openstack/neutron/plain/etc/policy.json?h=$OPENSTACK_TAG && \
44 wget -q -O /etc/glance/policy.json https://git.openstack.org/cgit/openstack/glance/plain/etc/policy.json?h=$OPENSTACK_TAG && \
45 git clone --depth 1 -b $NEUTRON_RALLY_TAG https://git.openstack.org/openstack/neutron.git /src/neutron && \
46 (cd /src/neutron && git fetch --tags origin $NEUTRON_RALLY_TAG && git checkout FETCH_HEAD) && \
47 mkdir -p /home/opnfv/functest/data/rally/neutron && \
48 cp -r /src/neutron/rally-jobs /home/opnfv/functest/data/rally/neutron/rally-jobs && \
49 rm -r /src/neutron && \
51 COPY testcases.yaml /usr/lib/python2.7/site-packages/xtesting/ci/testcases.yaml
52 CMD ["run_tests", "-t", "all"]