• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1FROM centos:6.9
2
3RUN yum install -y git \
4                   tar \
5                   wget \
6                   make \
7                   autoconf \
8                   curl-devel \
9                   unzip \
10                   automake \
11                   libtool \
12                   glibc-static.i686 \
13                   glibc-devel \
14                   glibc-devel.i686 \
15                   && \
16    yum clean all
17
18# Install Java 8
19RUN wget -q --no-cookies --no-check-certificate \
20    --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" \
21    "http://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-linux-x64.tar.gz" \
22    -O - | tar xz -C /var/local
23ENV JAVA_HOME /var/local/jdk1.8.0_131
24ENV PATH $JAVA_HOME/bin:$PATH
25
26# Install Maven
27RUN wget -q http://apache.cs.utah.edu/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.tar.gz -O - | \
28    tar xz -C /var/local
29ENV PATH /var/local/apache-maven-3.3.9/bin:$PATH
30
31# Install GCC 4.8 to support -static-libstdc++
32RUN wget http://people.centos.org/tru/devtools-2/devtools-2.repo -P /etc/yum.repos.d && \
33    bash -c 'echo "enabled=1" >> /etc/yum.repos.d/devtools-2.repo' && \
34    bash -c "sed -e 's/\$basearch/i386/g' /etc/yum.repos.d/devtools-2.repo > /etc/yum.repos.d/devtools-i386-2.repo" && \
35    sed -e 's/testing-/testing-i386-/g' -i /etc/yum.repos.d/devtools-i386-2.repo && \
36    rpm --rebuilddb
37
38RUN yum install -y devtoolset-2-gcc \
39                   devtoolset-2-gcc-c++ \
40                   devtoolset-2-binutils \
41                   devtoolset-2-libstdc++-devel \
42                   devtoolset-2-libatomic-devel \
43                   libatomic \
44                   devtoolset-2-gcc.i686 \
45                   devtoolset-2-gcc-c++.i686 \
46                   devtoolset-2-binutils.i686 \
47                   devtoolset-2-libstdc++-devel.i686 \
48                   devtoolset-2-libatomic-devel.i686 \
49                   libatomic.i686 && \
50    yum clean all
51
52COPY scl-enable-devtoolset.sh /var/local/
53
54# Start in devtoolset environment that uses GCC 4.7
55ENTRYPOINT ["/var/local/scl-enable-devtoolset.sh"]
56