You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by bc...@apache.org on 2018/07/31 21:08:24 UTC

[trafficserver] branch 8.0.x updated: Dockerfile for CentOS/Fedora, i.e. yum dependencies

This is an automated email from the ASF dual-hosted git repository.

bcall pushed a commit to branch 8.0.x
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/8.0.x by this push:
     new f874032  Dockerfile for CentOS/Fedora, i.e. yum dependencies
f874032 is described below

commit f874032ca63088860cd7ca0e5576de19f475df50
Author: Leif Hedstrom <zw...@apache.org>
AuthorDate: Tue Jul 24 11:22:51 2018 -0600

    Dockerfile for CentOS/Fedora, i.e. yum dependencies
    
    (cherry picked from commit 7b69a90be62d61b799b23a2f63dad74bab9253a7)
---
 ci/docker/yum/Dockerfile | 68 ++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 68 insertions(+)

diff --git a/ci/docker/yum/Dockerfile b/ci/docker/yum/Dockerfile
new file mode 100644
index 0000000..875016a
--- /dev/null
+++ b/ci/docker/yum/Dockerfile
@@ -0,0 +1,68 @@
+################################################################################
+#  Dockerfile to setup a CentOS / Fedora type docker image, suitable
+#  for building ATS, perhaps as part of a Jenkins CI. Note that some
+#  of the features in here are specific to the official ATS Jenkins
+#  setup, see comment below.
+#
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing, software
+#  distributed under the License is distributed on an "AS IS" BASIS,
+#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#  See the License for the specific language governing permissions and
+#  limitations under the License.
+
+################################################################################
+# These can (should?) be overriden from the command line with ----build-arg, e.g.
+#    docker build --build-arg OS_VERSION=7 --build-arg OS_TYPE=centos
+#
+ARG OS_VERSION=28
+ARG OS_TYPE=fedora
+
+# This does currently not work, e.g. this I'd expect to make it conditional:
+#
+#    RUN if [ "${ADD_JENKINS}" = "yes" ]; then yum ...
+#
+ARG ADD_JENKINS=no
+
+# Alright, lets pull in the base image from docker.io
+FROM ${OS_TYPE}:${OS_VERSION}
+
+################################################################################
+# All the DNF / YUM packages necessary for building ATS. you do not need all
+# these if you only intend to run ATS, see the .spec file for the required
+#runtime packages.
+
+# This runs all the yum installation, starting with a system level update
+RUN yum -y update; \
+    # Compilers
+    yum -y install ccache make pkgconfig bison flex gcc-c++ clang \
+    # Autoconf
+    autoconf automake libtool \
+    # Various other tools
+    git rpm-build distcc-server file; \
+    # Devel packages that ATS needs
+    yum -y install openssl-devel tcl-devel expat-devel pcre-devel libcap-devel hwloc-devel libunwind-devel \
+    xz-devel libcurl-devel ncurses-devel jemalloc-devel GeoIP-devel kyotocabinet-devel luajit-devel \
+    perl-ExtUtils-MakeMaker; \
+    # This is for autest stuff
+    yum -y install python3 python3-virtualenv python-virtualenv httpd-tools procps-ng; \
+    # Optional: This is for the OpenSSH server, and Jenkins account (comment out if not needed)
+    yum -y install openssh-server && ssh-keygen -A; rm -f /run/nologin; \
+    groupadd  -g 665 jenkins && \
+    useradd -g jenkins -u 989 -s /bin/bash -M -d /home/jenkins -c "Jenkins Continuous Build server" jenkins && \
+    mkdir -p /var/jenkins && chown jenkins.jenkins /var/jenkins
+
+# Check if devtoolset-7 is required
+RUN  if [ ! -z "$(grep -i centos /etc/redhat-release)" ]; then \
+    yum -y install centos-release-scl; \
+    yum -y install devtoolset-7 devtoolset-7-libasan-devel; \
+    fi