From e5f2c348e25b1f15e229bfb8e723123e19ad835d Mon Sep 17 00:00:00 2001 From: Noah Levitt Date: Tue, 15 Nov 2016 12:09:09 -0800 Subject: [PATCH] fix dockerized automated tests now that phusion/baseimage is ubuntu xenial --- setup.py | 2 +- tests/Dockerfile | 18 ++++++++++++++---- tests/run-tests.sh | 2 +- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/setup.py b/setup.py index 3103d0e..a02e6fe 100755 --- a/setup.py +++ b/setup.py @@ -51,7 +51,7 @@ except: setuptools.setup( name='warcprox', - version='2.0b2.dev36', + version='2.0b2.dev37', description='WARC writing MITM HTTP/S proxy', url='https://github.com/internetarchive/warcprox', author='Noah Levitt', diff --git a/tests/Dockerfile b/tests/Dockerfile index ab1f01a..8e57149 100644 --- a/tests/Dockerfile +++ b/tests/Dockerfile @@ -31,16 +31,26 @@ RUN apt-get update && apt-get --auto-remove -y dist-upgrade # Add the RethinkDB repository and public key # "RethinkDB Packaging " http://download.rethinkdb.com/apt/pubkey.gpg RUN apt-key adv --keyserver pgp.mit.edu --recv-keys 1614552E5765227AEC39EFCFA7E00EF33A8F2399 \ - && echo "deb http://download.rethinkdb.com/apt trusty main" > /etc/apt/sources.list.d/rethinkdb.list \ + && echo "deb http://download.rethinkdb.com/apt xenial main" > /etc/apt/sources.list.d/rethinkdb.list \ && apt-get update && apt-get -y install rethinkdb RUN mkdir -vp /etc/service/rethinkdb \ && echo "#!/bin/sh\nrethinkdb --bind 0.0.0.0 --directory /tmp/rethink-data --runuser rethinkdb --rungroup rethinkdb\n" > /etc/service/rethinkdb/run \ && chmod a+x /etc/service/rethinkdb/run -RUN apt-get -y install python-virtualenv git -RUN apt-get -y install python-gdbm python3-gdbm libpython2.7-dev libpython3.4-dev libffi-dev libssl-dev -RUN pip install devpi-client +RUN apt-get -y install git +RUN apt-get -y install python-gdbm python3-gdbm libpython2.7-dev \ + libpython3-dev libffi-dev libssl-dev python-setuptools \ + python3-setuptools +RUN apt-get -y install gcc + +RUN echo '57ff41e99cb01b6a1c2b0999161589b726f0ec8b /tmp/pip-9.0.1.tar.gz' > /tmp/sha1sums.txt +RUN curl -sSL -o /tmp/pip-9.0.1.tar.gz https://pypi.python.org/packages/11/b6/abcb525026a4be042b486df43905d6893fb04f05aac21c32c638e939e447/pip-9.0.1.tar.gz +RUN sha1sum -c /tmp/sha1sums.txt +RUN tar -C /tmp -xf /tmp/pip-9.0.1.tar.gz +RUN cd /tmp/pip-9.0.1 && python3 setup.py install + +RUN pip install virtualenv RUN apt-get -y install tor RUN mkdir -vp /etc/service/tor \ diff --git a/tests/run-tests.sh b/tests/run-tests.sh index b28e606..191dd70 100755 --- a/tests/run-tests.sh +++ b/tests/run-tests.sh @@ -33,7 +33,7 @@ script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" docker build -t internetarchive/warcprox-tests $script_dir -for python in python2.7 python3.4 +for python in python2.7 python3 do docker run --rm --volume="$script_dir/..:/warcprox" internetarchive/warcprox-tests /sbin/my_init -- \ bash -x -c "cd /tmp && git clone /warcprox && cd /tmp/warcprox \