]>
Commit | Line | Data |
---|---|---|
c25aa7cd PP |
1 | ARG BASE=centos:8 |
2 | ||
ad5611d8 TR |
3 | FROM ${BASE} AS stream |
4 | RUN dnf -y --disablerepo '*' --enablerepo=extras swap centos-linux-repos centos-stream-repos && \ | |
5 | dnf -y distro-sync | |
6 | ||
7 | FROM stream AS yum | |
c25aa7cd PP |
8 | RUN yum install -y \ |
9 | which \ | |
10 | bzip2 \ | |
11 | git \ | |
12 | libarchive \ | |
13 | cmake \ | |
14 | gcc \ | |
15 | make \ | |
16 | openssl-devel \ | |
17 | openssh-server \ | |
18 | git-daemon \ | |
19 | java-1.8.0-openjdk-headless \ | |
20 | sudo \ | |
21 | python39 \ | |
22 | krb5-workstation \ | |
23 | krb5-libs | |
24 | ||
25 | FROM yum AS libssh2 | |
26 | RUN cd /tmp && \ | |
27 | curl --location --silent --show-error https://www.libssh2.org/download/libssh2-1.8.0.tar.gz | tar -xz && \ | |
28 | cd libssh2-1.8.0 && \ | |
29 | ./configure && \ | |
30 | make && \ | |
31 | make install && \ | |
32 | cd .. && \ | |
33 | rm -rf libssh2-1.8.0 | |
34 | ||
35 | FROM libssh2 AS valgrind | |
36 | RUN cd /tmp && \ | |
37 | curl --insecure --location --silent --show-error https://sourceware.org/pub/valgrind/valgrind-3.15.0.tar.bz2 | \ | |
38 | tar -xj && \ | |
39 | cd valgrind-3.15.0 && \ | |
40 | ./configure && \ | |
41 | make MAKEFLAGS="-j -l$(grep -c ^processor /proc/cpuinfo)" && \ | |
42 | make install && \ | |
43 | cd .. && \ | |
44 | rm -rf valgrind-3.15.0 | |
45 | ||
46 | FROM valgrind AS adduser | |
ad5611d8 TR |
47 | ARG UID="" |
48 | ARG GID="" | |
49 | RUN if [ "${UID}" != "" ]; then USER_ARG="--uid ${UID}"; fi && \ | |
50 | if [ "${GID}" != "" ]; then GROUP_ARG="--gid ${GID}"; fi && \ | |
51 | groupadd ${GROUP_ARG} libgit2 && \ | |
52 | useradd ${USER_ARG} --gid libgit2 --shell /bin/bash --create-home libgit2 | |
c25aa7cd PP |
53 | |
54 | FROM adduser AS configure | |
55 | ENV PKG_CONFIG_PATH /usr/local/lib/pkgconfig | |
56 | RUN mkdir /var/run/sshd | |
57 | RUN echo "/usr/local/lib" > /etc/ld.so.conf.d/local && \ | |
58 | ldconfig |