Dockerfile_no_sse 3.54 KB
Newer Older
1
2
3
4
5
6
7
8
#
# Simple EOS Docker file
#
# Version 0.3

FROM centos:7
LABEL maintainer="Elvin Sindrilaru, esindril@cern.ch, CERN 2017"

9
10
ARG EOS_CODENAME

11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# Add extra repositories
COPY eos-docker/el-7/*.repo /etc/yum.repos.d/

# Add helper scripts
COPY eos-docker/image_scripts/*.sh /

# Add configuration files for EOS instance
COPY eos-docker/eos.sysconfig /etc/sysconfig/eos
COPY eos-docker/xrd.cf.* eos-docker/krb5.conf /etc/
COPY eos-docker/fuse.eosdockertest.conf /etc/eos/fuse.eosdockertest.conf
COPY eos-docker/fuse.conf /etc/eos/fuse.mount-1.conf
COPY eos-docker/fuse.conf /etc/eos/fuse.mount-2.conf
COPY eos-docker/fstfmd.dict /var/eos/md/

# Add configuration files for forwarding proxy server
COPY eos-docker/xrootd.conf /etc/tmpfiles.d/
COPY eos-docker/xrootd-fwd-proxy.cfg /etc/xrootd/

29
30
# Set correct path for the dependency repository based on the EOS version
# which is being built
31
RUN sed -i "s/__EOS_CODENAME__/${EOS_CODENAME}/g" /etc/yum.repos.d/eos.repo
32

33
34
RUN mkdir /var/tmp/eosxd-cache/ /var/tmp/eosxd-journal/

35
RUN adduser eos-user && adduser eosnobody
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50

# Docker will aggressively cache the following command, but this is fine, since
# these packages are not updated often.
RUN yum -y --nogpg install \
    at autoconf automake \
    bzip2 \
    centos-release-scl-rh cmake3 compat-libf2c-34 createrepo \
    emacs \
    gcc-c++ gdb git \
    heimdal-server heimdal-workstation \
    initscripts \
    krb5-server krb5-workstation \
    less libacl-devel libgfortran libtool \
    nano \
    parallel perl-Test-Harness python2 python2-pip python3 python3-pip \
Fabio Luchetti's avatar
Fabio Luchetti committed
51
    redhat-lsb-core redis rpm-build \
52
53
54
55
56
57
    sudo \
    vim \
    xauth \
    yum-plugin-priorities \
    && yum clean all

58
# Pre install version-locking to 4.11.3 some xrootd dependencies to help yum resolve them later
59
RUN yum -y --nogpg install xrootd-libs-4.11.3 xrootd-server-4.11.3 xrootd-server-libs-4.11.3 xrootd-client-4.11.3 xrootd-client-libs-4.11.3 \
60
    xrootd-4.11.3 xrootd-private-devel-4.11.3 xrootd-server-devel-4.11.3 xrootd-client-devel-4.11.3 python2-xrootd-4.11.3 python3-xrootd-4.11.3
61

62
63
64
65
66
67
68
69
# Install new EOS from created repo - the ADD command will reset the docker cache,
# and any commands after that point will be uncached.
ENV EOSREPODIR="/repo/eos"
ADD cc7_no_sse_artifacts ${EOSREPODIR}

# Special packages, must be installed un-cached.
RUN createrepo ${EOSREPODIR} \
    && echo -e "[eos-artifacts]\nname=EOS artifacts\nbaseurl=file://${EOSREPODIR}\ngpgcheck=0\nenabled=1\npriority=1" >> /etc/yum.repos.d/eos.repo \
70
    && yum -y --nogpg install davix \
71
    eos-archive eos-client eos-fuse eos-fusex eos-ns-inspect eos-server eos-test eos-testkeytab \
72
73
    && yum clean all

74
75
RUN if [ "${EOS_CODENAME}" != "diopside" ]; then yum -y --nogpg install quarkdb; fi

76
77
78
79
80
81
82
83
# *************
# NOTE: !UGLY!*
# *************
# This is an ugly hack but the FST ofs.tpc config requires /usr/bin/xrdcp
# and this is provided by the xrootd-client package. With EOS having eos-xrootd
# as dependency the xrdcp program is in /opt/eos/xrootd/bin/xrdcp and the
# xrootd-client package is no longer installed and therefore starting the FSTs
# fails. This happens on CC7 and C8.
84
RUN yum install -y --nogpg install xrootd-client-4.11.3
85

86
87
88
89
# Swap and use the forwardable keytab (installed by the eos-testkeytab package).
# This is useful for clients who reside on a private network and tunnel through a
# Network Address Translation (NAT) device. You can remove these lines if you don't need them.
RUN mv -f /etc/eos.keytab.fw /etc/eos.keytab
90
91
92
93
94

# Change owner of /var/spool/xrootd directory to daemon
RUN chown daemon:daemon /var/spool/xrootd

ENTRYPOINT ["/bin/bash"]