Dockerfile_xrd_testing 2.55 KB
Newer Older
1
2
3
4
5
6
#
# Simple EOS Docker file
#
# Version 0.2

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

# Add extra repositories
10
COPY eos-docker/el-7/*.repo /etc/yum.repos.d/
11
12

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

# Add configuration files for EOS instance
16
17
18
19
20
21
22
23
24
COPY eos-docker/eos.sysconfig /etc/sysconfig/eos
COPY eos-docker/xrd.cf.* eos-docker/krb5.conf /etc/
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/
25
26

RUN mkdir /var/tmp/eosxd-cache/ /var/tmp/eosxd-journal/
27

28
RUN adduser eos-user
29
30
31
32

# Docker will aggressively cache the following command, but this is fine, since
# these packages are not updated often.
RUN yum -y --nogpg install \
33
34
35
36
37
    at autoconf automake \
    bzip2 \
    centos-release-scl-rh cmake3 compat-libf2c-34 createrepo \
    emacs \
    gcc-c++ gdb git \
38
    heimdal-server heimdal-workstation \
39
    initscripts \
40
    krb5-server krb5-workstation \
41
42
43
    less libacl-devel libgfortran libtool \
    nano \
    parallel perl-Test-Harness \
44
    redhat-lsb-core rpm-build \
45
46
    sudo \
    vim \
47
    xauth \
48
    yum-plugin-priorities \
49
    && yum clean all
50
51
52
53

# 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"
54
ADD cc7_xrd_testing_artifacts ${EOSREPODIR}
55

56
57
58
59
60
61
# 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 \
    && yum -y --nogpg --enablerepo=xrootd-testing --setopt="eos-depend.exclude=xrootd*,python2-xrootd*" install \
    davix grid-hammer quarkdb \
    eos-archive eos-client eos-debuginfo eos-fuse eos-fusex eos-ns-inspect eos-server eos-test eos-testkeytab \
62
    && yum clean all
63

64
65
66
67
68
69
70
71
# Generate a new forwardable keytab 'eos-test+' to replace the not-forwardable
# one (installed by the eos-testkeytab package).
# This is useful to deploy EOS on Kubernetes clusters running on CERN's Cloud
# Infrastructure; you can remove these lines if you don't need one.
RUN yes | xrdsssadmin -k eos-test del /etc/eos.keytab \
    && yes | xrdsssadmin -u daemon -g daemon -k eos-test+ -n 1234567890123456789 add /etc/eos.keytab \
    && chown daemon:daemon /etc/eos.keytab \
    && chmod 400 /etc/eos.keytab
72

73
ENTRYPOINT ["/bin/bash"]