8 changed files with 253 additions and 9 deletions
@ -0,0 +1,37 @@
|
||||
FROM ubuntu:bionic |
||||
SHELL ["/bin/bash", "-c"] |
||||
|
||||
# dependencies |
||||
RUN apt-get update |
||||
RUN apt-get install -y build-essential |
||||
RUN apt-get install -y \ |
||||
automake pkg-config libtool |
||||
RUN apt-get install -y \ |
||||
python-dev python-pip python-virtualenv python-qt4 python-sip |
||||
|
||||
# curl is a better tool |
||||
RUN apt-get install -y curl |
||||
|
||||
RUN useradd --home-dir /home/chaum --create-home --shell /bin/bash --skel /etc/skel/ chaum |
||||
ARG core_version |
||||
ARG core_dist |
||||
ARG repo_name |
||||
RUN mkdir -p /home/chaum/${repo_name} |
||||
COPY ${repo_name} /home/chaum/${repo_name} |
||||
RUN ls -la /home/chaum |
||||
RUN chown -R chaum:chaum /home/chaum/${repo_name} |
||||
USER chaum |
||||
|
||||
# copy node software from the host and install |
||||
WORKDIR /home/chaum |
||||
RUN ls -la . |
||||
RUN ls -la ${repo_name} |
||||
RUN ls -la ${repo_name}/deps |
||||
RUN tar xaf ./${repo_name}/deps/${core_dist} -C /home/chaum |
||||
ENV PATH "/home/chaum/bitcoin-${core_version}/bin:${PATH}" |
||||
RUN bitcoind --version | head -1 |
||||
|
||||
# install script |
||||
WORKDIR ${repo_name} |
||||
RUN ./install.sh --no-gpg-validation |
||||
RUN source jmvenv/bin/activate && ./test/run_tests.sh |
||||
@ -0,0 +1,41 @@
|
||||
#!/bin/bash -x |
||||
|
||||
travis_docker_env () |
||||
{ |
||||
if [[ -n "${DOCKER_IMG_JM}" ]] && [[ "${HAS_JOSH_K_SEAL_OF_APPROVAL}" == true ]]; then |
||||
return 0 |
||||
else |
||||
return 1 |
||||
fi |
||||
} |
||||
|
||||
build_docker () |
||||
{ |
||||
if ! travis_docker_env; then |
||||
return 0 |
||||
fi |
||||
|
||||
core_version='0.16.1' |
||||
core_dist="bitcoin-${core_version}-x86_64-linux-gnu.tar.gz" |
||||
core_url="https://bitcoin.org/bin/bitcoin-core-${core_version}/${core_dist}" |
||||
jm_root="${TRAVIS_BUILD_DIR}" |
||||
owner_name="${TRAVIS_REPO_SLUG%\/*}" |
||||
repo_name="${TRAVIS_REPO_SLUG#*\/}" |
||||
|
||||
if [[ ! -f "${HOME}/downloads/${core_dist}" ]]; then |
||||
wget "${core_url}" -O "$HOME/downloads/${core_dist}" |
||||
fi |
||||
|
||||
mkdir -p "${jm_root}/deps" |
||||
cp "${HOME}/downloads/${core_dist}" "${jm_root}/deps/" |
||||
cd "${jm_root}/../" |
||||
|
||||
docker build \ |
||||
--shm-size=1G \ |
||||
--build-arg core_version="${core_version}" \ |
||||
--build-arg core_dist="${core_dist}" \ |
||||
--build-arg repo_name="${repo_name}" \ |
||||
-f "./${repo_name}/test/Dockerfiles/${DOCKER_IMG_JM}.Dockerfile" . |
||||
return "$?" |
||||
} |
||||
build_docker |
||||
@ -0,0 +1,33 @@
|
||||
FROM centos:7 |
||||
SHELL ["/bin/bash", "-c"] |
||||
|
||||
# dependencies |
||||
RUN yum -y groups install 'Development tools' |
||||
RUN yum -y install epel-release && \ |
||||
yum -y update |
||||
RUN yum -y install \ |
||||
python-devel python2-pip python-virtualenv |
||||
|
||||
RUN useradd --home-dir /home/chaum --create-home --shell /bin/bash --skel /etc/skel/ chaum |
||||
ARG core_version |
||||
ARG core_dist |
||||
ARG repo_name |
||||
RUN mkdir -p /home/chaum/${repo_name} |
||||
COPY ${repo_name} /home/chaum/${repo_name} |
||||
RUN ls -la /home/chaum |
||||
RUN chown -R chaum:chaum /home/chaum/${repo_name} |
||||
USER chaum |
||||
|
||||
# copy node software from the host and install |
||||
WORKDIR /home/chaum |
||||
RUN ls -la . |
||||
RUN ls -la ${repo_name} |
||||
RUN ls -la ${repo_name}/deps |
||||
RUN tar xaf ./${repo_name}/deps/${core_dist} -C /home/chaum |
||||
ENV PATH "/home/chaum/bitcoin-${core_version}/bin:${PATH}" |
||||
RUN bitcoind --version | head -1 |
||||
|
||||
# install script |
||||
WORKDIR ${repo_name} |
||||
RUN ./install.sh --no-gpg-validation |
||||
RUN source jmvenv/bin/activate && ./test/run_tests.sh |
||||
@ -0,0 +1,36 @@
|
||||
FROM fedora:27 |
||||
SHELL ["/bin/bash", "-c"] |
||||
|
||||
# dependencies |
||||
RUN dnf -y groups install 'Development tools' |
||||
RUN dnf -y install \ |
||||
autoconf libtool pkgconfig \ |
||||
python-devel python-pip python2-virtualenv |
||||
|
||||
# needed for build time |
||||
# https://stackoverflow.com/questions/34624428/g-error-usr-lib-rpm-redhat-redhat-hardened-cc1-no-such-file-or-directory |
||||
RUN dnf -y install redhat-rpm-config |
||||
|
||||
RUN useradd --home-dir /home/chaum --create-home --shell /bin/bash --skel /etc/skel/ chaum |
||||
ARG core_version |
||||
ARG core_dist |
||||
ARG repo_name |
||||
RUN mkdir -p /home/chaum/${repo_name} |
||||
COPY ${repo_name} /home/chaum/${repo_name} |
||||
RUN ls -la /home/chaum |
||||
RUN chown -R chaum:chaum /home/chaum/${repo_name} |
||||
USER chaum |
||||
|
||||
# copy node software from the host and install |
||||
WORKDIR /home/chaum |
||||
RUN ls -la . |
||||
RUN ls -la ${repo_name} |
||||
RUN ls -la ${repo_name}/deps |
||||
RUN tar xaf ./${repo_name}/deps/${core_dist} -C /home/chaum |
||||
ENV PATH "/home/chaum/bitcoin-${core_version}/bin:${PATH}" |
||||
RUN bitcoind --version | head -1 |
||||
|
||||
# install script |
||||
WORKDIR ${repo_name} |
||||
RUN ./install.sh --no-gpg-validation |
||||
RUN source jmvenv/bin/activate && ./test/run_tests.sh |
||||
@ -0,0 +1,37 @@
|
||||
FROM debian:stretch |
||||
SHELL ["/bin/bash", "-c"] |
||||
|
||||
# dependencies |
||||
RUN apt-get update |
||||
RUN apt-get install -y build-essential |
||||
RUN apt-get install -y \ |
||||
automake pkg-config libtool |
||||
RUN apt-get install -y \ |
||||
python-dev python-pip python-virtualenv python-qt4 python-sip |
||||
|
||||
# curl is a better tool |
||||
RUN apt-get install -y curl |
||||
|
||||
RUN useradd --home-dir /home/chaum --create-home --shell /bin/bash --skel /etc/skel/ chaum |
||||
ARG core_version |
||||
ARG core_dist |
||||
ARG repo_name |
||||
RUN mkdir -p /home/chaum/${repo_name} |
||||
COPY ${repo_name} /home/chaum/${repo_name} |
||||
RUN ls -la /home/chaum |
||||
RUN chown -R chaum:chaum /home/chaum/${repo_name} |
||||
USER chaum |
||||
|
||||
# copy node software from the host and install |
||||
WORKDIR /home/chaum |
||||
RUN ls -la . |
||||
RUN ls -la ${repo_name} |
||||
RUN ls -la ${repo_name}/deps |
||||
RUN tar xaf ./${repo_name}/deps/${core_dist} -C /home/chaum |
||||
ENV PATH "/home/chaum/bitcoin-${core_version}/bin:${PATH}" |
||||
RUN bitcoind --version | head -1 |
||||
|
||||
# install script |
||||
WORKDIR ${repo_name} |
||||
RUN ./install.sh --no-gpg-validation |
||||
RUN source jmvenv/bin/activate && ./test/run_tests.sh |
||||
@ -0,0 +1,37 @@
|
||||
FROM ubuntu:xenial |
||||
SHELL ["/bin/bash", "-c"] |
||||
|
||||
# dependencies |
||||
RUN apt-get update |
||||
RUN apt-get install -y build-essential |
||||
RUN apt-get install -y \ |
||||
automake pkg-config libtool |
||||
RUN apt-get install -y \ |
||||
python-dev python-pip python-virtualenv python-qt4 python-sip |
||||
|
||||
# curl is a better tool |
||||
RUN apt-get install -y curl |
||||
|
||||
RUN useradd --home-dir /home/chaum --create-home --shell /bin/bash --skel /etc/skel/ chaum |
||||
ARG core_version |
||||
ARG core_dist |
||||
ARG repo_name |
||||
RUN mkdir -p /home/chaum/${repo_name} |
||||
COPY ${repo_name} /home/chaum/${repo_name} |
||||
RUN ls -la /home/chaum |
||||
RUN chown -R chaum:chaum /home/chaum/${repo_name} |
||||
USER chaum |
||||
|
||||
# copy node software from the host and install |
||||
WORKDIR /home/chaum |
||||
RUN ls -la . |
||||
RUN ls -la ${repo_name} |
||||
RUN ls -la ${repo_name}/deps |
||||
RUN tar xaf ./${repo_name}/deps/${core_dist} -C /home/chaum |
||||
ENV PATH "/home/chaum/bitcoin-${core_version}/bin:${PATH}" |
||||
RUN bitcoind --version | head -1 |
||||
|
||||
# install script |
||||
WORKDIR ${repo_name} |
||||
RUN ./install.sh --no-gpg-validation |
||||
RUN source jmvenv/bin/activate && ./test/run_tests.sh |
||||
Loading…
Reference in new issue