-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
58 lines (52 loc) · 1.53 KB
/
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
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
ENV VCPKG_FORCE_SYSTEM_BINARIES=1
WORKDIR /build
COPY . .
RUN apt-get -qq update \
&& apt-get -qq install apt-utils gpg locales lsb-release wget \
&& echo en_US.UTF-8 UTF-8 >> /etc/locale.gen \
&& wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | tee /usr/share/keyrings/kitware-archive-keyring.gpg >/dev/null \
&& echo "deb [signed-by=/usr/share/keyrings/kitware-archive-keyring.gpg] https://apt.kitware.com/ubuntu/ $(lsb_release -cs) main" | tee /etc/apt/sources.list.d/kitware.list >/dev/null \
&& apt-get -qq update \
&& rm /usr/share/keyrings/kitware-archive-keyring.gpg \
&& apt-get -qq install kitware-archive-keyring \
&& apt-get -qq install autoconf \
build-essential \
cmake \
curl \
g++ \
gcc \
git \
libboost-all-dev \
libc-ares-dev \
libcrypto++-dev \
libcurl4-openssl-dev \
libraw-dev \
libreadline-dev \
libsodium-dev \
libsqlite3-dev \
libssl-dev \
ninja-build \
p7zip-full \
pkg-config \
python3 \
python3-pip \
software-properties-common \
tar \
unzip \
xz-utils \
yasm \
zip \
zlib1g-dev \
&& rm -rf /var/lib/apt/lists/* \
&& rm -rf /tmp/* \
&& python3 build.py
FROM ubuntu:22.04
WORKDIR /app
COPY --from=builder /build/cmake-build-debug/megasdkrestpp .
RUN apt-get -qq update \
&& apt-get -qq install libc-ares-dev libcurl4 \
&& rm -rf /var/lib/apt/lists/* \
&& rm -rf /tmp/*
CMD [ "./megasdkrestpp" ]