summaryrefslogtreecommitdiffstats
path: root/99-ci-maipo/Dockerfile
blob: dbd19853fe7b9dd00d0b09ae786f71e9f804edd1 (plain)
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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
FROM centos:centos7
MAINTAINER Kolab Systems <vanmeeuwen@kolabsys.com>

RUN rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

RUN sed -r -i \
        -e 's/^mirrorlist/#mirrorlist/g' \
        -e 's/^#baseurl/baseurl/g' \
        /etc/yum.repos.d/*.repo && \
    sed -i \
        -e '/tsflags=nodocs/d' \
        -e '/override_install_langs/d' \
        /etc/yum.conf && \
    sed -r -i \
        -e 's/enabled\s*=\s*1/enabled=0/g' \
        /etc/yum/pluginconf.d/fastestmirror.conf

RUN yum -y install wget && \
    yum clean all

RUN wget -O/etc/yum.repos.d/Kolab:Winterfell.repo \
        http://obs.kolabsys.com/repositories/Kolab:/Winterfell/CentOS_7/Kolab:Winterfell.repo

RUN wget -O/etc/yum.repos.d/Kolab:16.repo \
        http://obs.kolabsys.com/repositories/Kolab:/16/CentOS_7/Kolab:16.repo

RUN echo "priority=60" >> /etc/yum.repos.d/Kolab:Winterfell.repo

RUN echo "priority=60" >> /etc/yum.repos.d/Kolab:16.repo

RUN rpm --import https://ssl.kolabsys.com/community.asc

RUN wget -O/etc/yum.repos.d/openSUSE:Tools.repo \
        http://download.opensuse.org/repositories/openSUSE:Tools/CentOS_7/openSUSE:Tools.repo

RUN rpm --import http://download.opensuse.org/repositories/openSUSE:/Tools/CentOS_7/repodata/repomd.xml.key

ENV IMAGE maipo

ADD /dbus.service /etc/systemd/system/dbus.service
RUN ln -sf dbus.service /etc/systemd/system/messagebus.service

ADD /httpd.service /etc/systemd/system/httpd.service

ADD /vimrc /root/.vimrc

RUN yum clean all && \
    yum -y install epel-release && \
    rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7 && \
    sed -i \
        -e 's/#baseurl/baseurl/g' \
        -e '/^mirrorlist/d' \
        /etc/yum.repos.d/epel*.repo && \
    yum -y install yum-plugin-priorities && \
    yum -y update && \
    yum -y install \
        @buildsys-build \
        ant \
        bind-utils \
        build \
        git \
        lsof \
        net-tools \
        nmap-ncat \
        openldap-clients \
        osc \
        perl-Data-Dumper \
        perl-Digest-MD5 \
        perl-TimeDate \
        php-phpunit-PHPUnit-Selenium \
        policycoreutils \
        policycoreutils-python \
        psmisc \
        rpmdevtools \
        screen \
        strace \
        sudo \
        telnet \
        traceroute \
        vim-enhanced \
        wget \
        yum-utils && \
    yum clean all

ADD /systemctl /usr/bin/systemctl
ADD /systemctl-socket-daemon /usr/bin/systemctl-socket-daemon

RUN chmod -v a+rx \
    /usr/bin/systemctl \
    /usr/bin/systemctl-socket-daemon

RUN mkdir -p /run/lock
RUN ln -sf /bin/true /sbin/semanage

RUN sed -i -e '/requiretty/d' /etc/sudoers

WORKDIR /srv
RUN git clone https://github.com/google/closure-compiler.git closure-compiler.git
WORKDIR /srv/closure-compiler.git
RUN ant jar

RUN wget \
        -O/usr/local/lib/selenium-server-standalone.jar \
        http://mirror.kolabenterprise.com/pub/releases/selenium-server-standalone.jar

ADD /functions.sh /functions.sh
ADD /entrypoint.sh /entrypoint.sh

RUN chmod a+x /entrypoint.sh

ENTRYPOINT [ "/entrypoint.sh" ]