forked from publicarray/docker-ntpsec
-
Notifications
You must be signed in to change notification settings - Fork 0
/
builder-centos_8
36 lines (30 loc) · 1.57 KB
/
builder-centos_8
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
FROM centos:8
RUN dnf -y install unzip wget bison gcc gcc-c++ make openssl-devel libcap-devel python3-devel libseccomp-devel kernel-devel kernel-headers
RUN dnf -y --enablerepo=PowerTools install pps-tools-devel avahi-compat-libdns_sd-devel
RUN dnf -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm && dnf -y --enablerepo=epel install python3-gpsd libbsd-devel
ENV NTPSEC_VERSION 1.1.9
ENV NTPSEC_DOWNLOAD_URL "https://ftp.ntpsec.org/pub/releases/ntpsec-${NTPSEC_VERSION}.tar.gz"
ENV NTPSEC_SHA256 0acade979a807a047c2a8fd7f497235d9d6a5d0d54726e5d27505506d6ec00cc
ENV PPS_TOOLS_DOWNLOAD_URL "https://github.com/redlab-i/pps-tools/archive/master.zip"
ENV PPS_TOOLS_SHA256 48f09d2690af18ef12bb61ab8e39788d625fc8c2c2fb86a1c990d7de73d4b437
RUN set -x && \
mkdir -p /tmp-pps-tools && \
cd /tmp-pps-tools && \
wget -O pps-tools.zip $PPS_TOOLS_DOWNLOAD_URL && \
echo "${PPS_TOOLS_SHA256} *pps-tools.zip" | sha256sum -c - && \
unzip -j pps-tools.zip
RUN set -x && \
mkdir -p /tmp-ntpsec && \
cd /tmp-ntpsec && \
wget -O ntpsec.tar.gz $NTPSEC_DOWNLOAD_URL && \
echo "${NTPSEC_SHA256} *ntpsec.tar.gz" | sha256sum -c - && \
tar xzf ntpsec.tar.gz --strip-components=1
RUN set -x && \
cd /tmp-pps-tools && \
make install && \
cd /tmp-ntpsec && \
alternatives --set python /usr/bin/python3 && \
./waf configure --prefix=/usr --python=python3 --disable-doc --disable-manpage --enable-leap-smear --enable-mssntp --enable-seccomp --refclock=all && \
./waf build --verbose && \
./waf check --verbose && \
./waf install