configure dockerfile with travis

This commit is contained in:
Muzahid 2021-01-11 12:06:33 +05:30
parent 8ca42c3773
commit f9009a23a5
1 changed files with 12 additions and 48 deletions

View File

@ -8,19 +8,13 @@ RUN apt-get update
RUN apt-get -y install sudo
RUN sudo chmod -R 777 /var/lib/dpkg/lock-frontend
# RUN apt-get install -y apt-utils
# RUN dpkg-reconfigure -au
# travis xenial bionic
RUN apt-get install -yq --no-install-suggests --no-install-recommends \
python-setuptools libssl-dev python-dev python-virtualenv python-pip
python-setuptools libssl-dev libpq-dev python-prctl python-dev python-dev python-virtualenv python-pip
# travis focal
RUN apt-get install -yq --no-install-suggests --no-install-recommends \
python-setuptools libssl-dev python-dev python3-virtualenv python3-pip
python-setuptools libpcap-dev libpq-dev python-prctl python-dev libpcap-dev python3-virtualenv python3-pip
# dpkg
RUN apt-get install -yq --no-install-suggests --no-install-recommends \
@ -54,17 +48,23 @@ RUN useradd -ms /bin/bash pool
RUN echo 'pool ALL=ALL NOPASSWD:ALL' >> /etc/sudoers
# bionic-travis.docker
#ENV HOME=/home
# Travis start
# $USER pool
FROM pybm-build as pybm-travis
# RUN sudo chown -R $USER $HOME
RUN pip install --upgrade setuptools
ENV HOME /root
WORKDIR $HOME
RUN git clone https://github.com/Bitmessage/PyBitmessage
RUN apt-get install python-prctl
RUN apt-get -y install g++
WORKDIR $HOME/PyBitmessage
ENV PATH $HOME/.local/bin:$PATH
@ -74,39 +74,3 @@ RUN python setup.py install --user
RUN python checkdeps.py
RUN xvfb-run src/bitmessagemain.py -t
RUN python setup.py test
# bionic-travis.docker
# FROM pybm-build
USER pool
RUN mkdir $HOME/Downloads
WORKDIR $HOME/Downloads
RUN wget https://download.microsoft.com/download/7/9/6/796EF2E4-801B-4FC4-AB28-B59FBF6D907B/VCForPython27.msi
WORKDIR $HOME
RUN git clone https://github.com/Bitmessage/PyBitmessage
WORKDIR $HOME/PyBitmessage
ENV PATH $HOME/.local/bin:$PATH
RUN ln -s src pybitmessage
# 64b
RUN xvfb-run buildscripts/winbuild.sh
ENV WINEPREFIX $HOME/.wine64
ENV WINEARCH=win64
RUN xvfb-run wine msiexec -i $HOME/Downloads/VCForPython27.msi /q /norestart
RUN xvfb-run winetricks -q dotnet40
RUN xvfb-run wine pip install wheel
RUN xvfb-run wine python setup.py test
# 32b
RUN xvfb-run i386 buildscripts/winbuild.sh
ENV WINEPREFIX $HOME/.wine32
ENV WINEARCH=wine32
RUN xvfb-run i386 wine msiexec -i $HOME/Downloads/VCForPython27.msi /q /norestart
RUN xvfb-run i386 winetricks -q dotnet40
RUN xvfb-run i386 wine pip install wheel
RUN xvfb-run i386 wine python setup.py test