2020-06-18 16:44:22 +00:00
|
|
|
FROM a12e/docker-qt:5.14-gcc_64
|
|
|
|
|
2020-10-06 18:37:57 +00:00
|
|
|
# $QT_PATH and $QT_PLATFORM are provided by the docker image
|
|
|
|
# $QT_PATH/$QT_VERSION/$QT_PLATFORM/bin is already prepended to $PATH
|
|
|
|
# However $QT_VERSION is not exposed to environment so set it here
|
|
|
|
ENV QT_VERSION="5.14.0"
|
2021-04-21 20:13:21 +00:00
|
|
|
ENV QTDIR="${QT_PATH}/${QT_VERSION}/${QT_PLATFORM}"
|
|
|
|
ENV LD_LIBRARY_PATH="${QTDIR}/lib:${LD_LIBRARY_PATH}"
|
2020-10-06 18:37:57 +00:00
|
|
|
# $OPENSSL_PREFIX is provided by the docker image
|
|
|
|
ENV LIBRARY_PATH="${OPENSSL_PREFIX}/lib:${LIBRARY_PATH}"
|
2022-01-20 23:28:31 +00:00
|
|
|
ENV OPENSSL_ROOT_DIR="${OPENSSL_PREFIX}"
|
2020-10-06 18:37:57 +00:00
|
|
|
|
2020-06-18 16:44:22 +00:00
|
|
|
RUN export DEBIAN_FRONTEND=noninteractive \
|
|
|
|
&& sudo apt update -yq \
|
|
|
|
&& sudo apt install -yq software-properties-common \
|
|
|
|
&& sudo add-apt-repository -y ppa:git-core/ppa \
|
2022-01-20 23:28:31 +00:00
|
|
|
&& sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test \
|
2020-06-18 16:44:22 +00:00
|
|
|
&& sudo apt update -yq \
|
2021-08-04 15:41:31 +00:00
|
|
|
&& sudo apt purge -yq gnupg \
|
2020-06-18 16:44:22 +00:00
|
|
|
&& sudo apt install -yq --fix-missing \
|
2022-01-20 23:28:31 +00:00
|
|
|
jq git s3cmd gnupg2 ca-certificates \
|
|
|
|
build-essential extra-cmake-modules gcc-9 g++-9 \
|
2021-11-22 10:27:15 +00:00
|
|
|
libpcre3-dev libnss3 libxcomposite1 libxtst6 libpcsclite-dev \
|
2021-08-04 15:41:31 +00:00
|
|
|
gstreamer1.0-plugins-good gstreamer1.0-plugins-bad \
|
|
|
|
gstreamer1.0-plugins-ugly gstreamer1.0-libav \
|
2021-11-22 10:27:15 +00:00
|
|
|
gstreamer1.0-tools gstreamer1.0-alsa gstreamer1.0-pulseaudio
|
2020-06-18 16:44:22 +00:00
|
|
|
|
2022-01-20 23:28:31 +00:00
|
|
|
# C++17 is required
|
|
|
|
RUN sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 100 \
|
|
|
|
--slave /usr/bin/g++ g++ /usr/bin/g++-9
|
|
|
|
|
|
|
|
# CMake 3.16 or higher is required
|
|
|
|
RUN wget https://github.com/Kitware/CMake/releases/download/v3.22.1/cmake-3.22.1-linux-x86_64.sh \
|
|
|
|
&& chmod +x cmake-3.22.1-linux-x86_64.sh \
|
|
|
|
&& sudo mkdir /opt/cmake \
|
|
|
|
&& sudo sh cmake-3.22.1-linux-x86_64.sh --prefix=/opt/cmake --exclude-subdir --skip-license \
|
|
|
|
&& rm -f cmake-3.22.1-linux-x86_64.sh
|
|
|
|
ENV PATH="/opt/cmake/bin:${PATH}"
|
|
|
|
|
2021-11-22 12:04:11 +00:00
|
|
|
# Fix LetsEncrypt X3 root certificate expliration
|
|
|
|
RUN sudo sed -i 's#\(mozilla/DST_Root_CA_X3.crt\)#!\1#' /etc/ca-certificates.conf \
|
|
|
|
&& sudo dpkg-reconfigure -fnoninteractive ca-certificates
|
|
|
|
|
2020-06-18 16:44:22 +00:00
|
|
|
# Installing Golang
|
2022-08-02 20:33:25 +00:00
|
|
|
RUN GOLANG_SHA256="9e5de37f9c49942c601b191ac5fba404b868bfc21d446d6960acc12283d6e5f2" \
|
|
|
|
&& GOLANG_TARBALL="go1.18.5.linux-amd64.tar.gz" \
|
2020-06-18 16:44:22 +00:00
|
|
|
&& wget -q "https://dl.google.com/go/${GOLANG_TARBALL}" \
|
|
|
|
&& echo "${GOLANG_SHA256} ${GOLANG_TARBALL}" | sha256sum -c \
|
|
|
|
&& sudo tar -C /usr/local -xzf "${GOLANG_TARBALL}" \
|
|
|
|
&& rm "${GOLANG_TARBALL}" \
|
|
|
|
&& sudo ln -s /usr/local/go/bin/go /usr/local/bin
|
|
|
|
|
2020-10-06 18:37:57 +00:00
|
|
|
# Re-install Qt with QtWebEngine by adjusting QT_CI_PACKAGES
|
|
|
|
# The http_proxy=invalid is a fix for getting stuck on 'Welcome Page'
|
|
|
|
RUN sudo sed /tmp/build/install-qt.sh -i \
|
2022-03-10 13:25:22 +00:00
|
|
|
-e 's/^QT_CI_PACKAGES=.*/export QT_CI_PACKAGES=qt.qt5.5140.gcc_64,qt.qt5.5140.qtwebengine,qt.qt5,qt.qt5.5140.qtlottie/' \
|
2020-10-06 18:37:57 +00:00
|
|
|
-e '\#^/tmp/build/bin/extract-qt-installer.*#i export http_proxy=invalid' \
|
|
|
|
&& sudo -E /tmp/build/install-qt.sh
|
2020-06-18 16:44:22 +00:00
|
|
|
|
|
|
|
# Jenkins user needs a specific UID/GID to work
|
|
|
|
RUN sudo groupadd -g 1001 jenkins \
|
|
|
|
&& sudo useradd --create-home -u 1001 -g 1001 jenkins
|
|
|
|
USER jenkins
|
|
|
|
ENV HOME="/home/jenkins"
|
|
|
|
|
|
|
|
LABEL maintainer="jakub@status.im"
|
2021-08-04 15:41:31 +00:00
|
|
|
LABEL source="https://github.com/status-im/status-desktop"
|
2020-06-18 16:44:22 +00:00
|
|
|
LABEL description="Build image for the Status Desktop client written in Nim."
|