|
1 | | -FROM ubuntu:22.04 |
| 1 | +FROM alpine:3.19.0 |
2 | 2 |
|
3 | | -RUN apt-get update && \ |
4 | | - DEBIAN_FRONTEND="noninteractive" apt-get install -y --no-install-recommends \ |
5 | | - ca-certificates \ |
6 | | - build-essential \ |
7 | | - cmake \ |
8 | | - git \ |
9 | | - libopus-dev \ |
10 | | - libsodium-dev \ |
11 | | - libvpx-dev \ |
12 | | - ninja-build \ |
13 | | - nodejs \ |
14 | | - npm \ |
15 | | - pkg-config \ |
16 | | - && apt-get clean \ |
17 | | - && rm -rf /var/lib/apt/lists/* |
| 3 | +RUN ["apk", "add", "--no-cache", \ |
| 4 | + "cmake", \ |
| 5 | + "diffutils", \ |
| 6 | + "g++", \ |
| 7 | + "gcc", \ |
| 8 | + "git", \ |
| 9 | + "libsodium-dev", \ |
| 10 | + "libvpx-dev", \ |
| 11 | + "linux-headers", \ |
| 12 | + "make", \ |
| 13 | + "musl-dev", \ |
| 14 | + "npm", \ |
| 15 | + "opus-dev", \ |
| 16 | + "pkgconfig", \ |
| 17 | + "python3", \ |
| 18 | + "samurai"] |
18 | 19 |
|
19 | 20 | WORKDIR /work/c-toxcore |
20 | | -RUN git clone --depth=1 --recurse-submodules --shallow-submodules --branch=master https://github.com/TokTok/c-toxcore.git /work/c-toxcore |
21 | | -RUN cmake -B_build -H. -GNinja |
22 | | -RUN cmake --build _build --target install |
| 21 | +RUN ["git", "clone", "--depth=1", \ |
| 22 | + "--recurse-submodules", "--shallow-submodules", \ |
| 23 | + "--branch=master", \ |
| 24 | + "https://github.com/TokTok/c-toxcore.git", "/work/c-toxcore"] |
| 25 | +RUN ["cmake", "-B_build", "-H.", "-GNinja", "-DBOOTSTRAP_DAEMON=OFF"] |
| 26 | +RUN ["cmake", "--build", "_build", "--target", "install"] |
23 | 27 |
|
24 | 28 | WORKDIR /work/js-toxcore-c |
25 | 29 | COPY . /work/js-toxcore-c/ |
26 | 30 | ENV LD_LIBRARY_PATH=/usr/local/lib |
27 | | -RUN ls -l /usr/local/lib/libtoxcore.so |
28 | | -RUN npm install |
29 | | -RUN npm run doc |
30 | | -RUN npm run test |
31 | | -RUN npm run coverage |
32 | | -RUN npm run format |
33 | | -#COPY . /work/js-toxcore-c.orig/ |
34 | | -#RUN diff -ru /work/js-toxcore-c /work/js-toxcore-c.orig |
| 31 | +RUN ["ls", "-lh", "/usr/local/lib/libtoxcore.so.2"] |
| 32 | +RUN ["npm", "install"] |
| 33 | +RUN ["npm", "run", "doc"] |
| 34 | +RUN ["npm", "run", "test"] |
| 35 | +RUN ["npm", "run", "coverage"] |
| 36 | +RUN ["npm", "run", "format"] |
| 37 | +COPY . /work/js-toxcore-c.orig/ |
| 38 | +RUN rm -rf \ |
| 39 | + /work/js-toxcore-c*/.nyc_output \ |
| 40 | + /work/js-toxcore-c*/doc \ |
| 41 | + /work/js-toxcore-c*/node_modules \ |
| 42 | + /work/js-toxcore-c*/coverage.lcov \ |
| 43 | + /work/js-toxcore-c*/package-lock.json |
| 44 | +RUN diff -ru /work/js-toxcore-c /work/js-toxcore-c.orig |
0 commit comments