forked from criteo/JVips
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
60 lines (50 loc) · 1.45 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
59
60
FROM centos:7.2.1511
# Set default build arguments.
ARG NODE_VERSION=10.x
# Set default user (overriden in the command line with Jenkins' actual user).
ARG UNAME=jenkins
ARG UID=1000
ARG GID=1000
# Set default environment variables.
ENV JAVA_HOME=/usr/lib/jvm/java-openjdk
ENV PATH="${OSX_CROSS_HOME}/bin:${PATH}"
ENV YUM_OPTIONS="-y --setopt=skip_missing_names_on_install=False"
RUN yum install ${YUM_OPTIONS} \
centos-release-scl \
https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
# Install system dependencies.
RUN yum install ${YUM_OPTIONS} \
wget \
git \
cmake3 \
rh-maven35 \
meson \
ninja-build \
patch \
clang \
devtoolset-7-toolchain \
nasm \
yasm \
autoconf \
automake \
libtool \
diffutils \
openssl-devel \
expat-devel \
zlib-devel \
libxml2-devel \
xz xz-devel \
mpfr-devel \
gmp-devel \
libmpc-devel \
gtk-doc \
gobject-introspection gobject-introspection-devel \
glib2.x86_64 glib2-devel.x86_64 \
java-1.8.0-openjdk
RUN ln -s /usr/bin/cmake3 /usr/bin/cmake
# Switch to a non-root user.
RUN groupadd -g $GID -o $UNAME
RUN useradd -l -m -u $UID -g $GID -o -s /bin/bash -d /home/$UNAME $UNAME
RUN echo 'for scl in /opt/rh/*/enable; do source $scl; done' >> /etc/profile.d/rhscl.sh
USER $UNAME
CMD bash -l -ex build.sh --with-linux --without-w64 --without-macos