-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathdev.Dockerfile
105 lines (95 loc) · 3.47 KB
/
dev.Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
FROM ubuntu:18.04
RUN apt-get update && \
apt-get install --no-install-recommends -y \
gpg \
gpg-agent \
wget \
software-properties-common \
curl \
python3 \
python3-pip \
python3-setuptools \
python3-dev \
&& wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - && \
add-apt-repository -y "deb http://apt.llvm.org/bionic/ llvm-toolchain-bionic-9 main" && \
apt-add-repository -y ppa:bitcoin/bitcoin && \
add-apt-repository -y ppa:ubuntu-toolchain-r/test && \
add-apt-repository ppa:longsleep/golang-backports
# install dependencies
RUN apt-get update && apt-get upgrade -y && \
apt-get install --no-install-recommends -y \
libqt5gui5 libqt5core5a libqt5dbus5 qttools5-dev qttools5-dev-tools \
libqrencode-dev \
libprotobuf-dev protobuf-compiler \
libzmq3-dev \
libdb4.8-dev \
libdb4.8++-dev \
libzmq3-dev \
libminiupnpc-dev \
build-essential \
libtool \
autotools-dev \
automake \
pkg-config \
libssl-dev \
libevent-dev \
bsdmainutils \
libboost-system-dev \
libboost-filesystem-dev \
libboost-chrono-dev \
libboost-test-dev \
libboost-thread-dev \
libboost-python-dev \
libb2-dev
# install tools
RUN apt-get install --no-install-recommends -y \
libz-dev \
xz-utils \
gcc-9 \
g++-9 \
llvm-9 \
clang-9 \
clang-tidy-9 \
clang-format-9 \
git \
ccache \
lcov \
vim \
unzip \
golang-go \
&& rm -rf /var/lib/apt/lists/*
# set default compilers and tools
RUN update-alternatives --install /usr/bin/gcov gcov /usr/bin/gcov-9 90 && \
update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 90 && \
update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-9 90 && \
update-alternatives --install /usr/bin/clang clang /usr/lib/llvm-9/bin/clang-9 90 && \
update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-9 90 && \
update-alternatives --install /usr/bin/clang-tidy clang-tidy /usr/bin/clang-tidy-9 90 && \
update-alternatives --install /usr/bin/clang-format clang-format /usr/bin/clang-format-9 90 && \
update-alternatives --install /usr/bin/python python /usr/bin/python3 90
WORKDIR /tmp
RUN mkdir -p cmake && \
( \
cd cmake; \
wget https://github.com/Kitware/CMake/releases/download/v3.11.4/cmake-3.11.4.tar.gz; \
tar -zxf cmake-3.11.4.tar.gz; \
cd cmake-3.11.4/; \
./bootstrap; \
make -j2; \
make install; \
) && \
rm -rf cmake
RUN ldconfig
ENV SONAR_CLI_VERSION=4.2.0.1873
RUN set -e; \
mkdir -p /opt/sonar; \
curl -L -o /tmp/sonar.zip https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-${SONAR_CLI_VERSION}-linux.zip; \
unzip -o -d /tmp/sonar-scanner /tmp/sonar.zip; \
mv /tmp/sonar-scanner/sonar-scanner-${SONAR_CLI_VERSION}-linux /opt/sonar/scanner; \
ln -s -f /opt/sonar/scanner/bin/sonar-scanner /usr/local/bin/sonar-scanner; \
rm -rf /tmp/sonar*
ENV LC_ALL=C.UTF-8
ENV LANG=C.UTF-8
ENV PATH $PATH:/usr/local/go/bin
RUN pip3 install --upgrade setuptools wheel bashlex compiledb gcovr
WORKDIR /