From 7aad5150f69da42b84994c353283db5daf8e967f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Javier=20Jard=C3=B3n?= <jjardon@gnome.org>
Date: Sun, 26 Nov 2017 23:40:38 +0000
Subject: Add BuildStream converted files

This is made by a conversion made in
commit 8f8992a18d55c3abf28d4b6fc8036bd39d3dc1cf of definitions

Check there to know what exact versions of YBD and defs2bst was used
---
 elements/unmaintained/ntpd/ntpd.bst | 58 +++++++++++++++++++++++++++++++++++++
 1 file changed, 58 insertions(+)
 create mode 100644 elements/unmaintained/ntpd/ntpd.bst

(limited to 'elements/unmaintained/ntpd/ntpd.bst')

diff --git a/elements/unmaintained/ntpd/ntpd.bst b/elements/unmaintained/ntpd/ntpd.bst
new file mode 100644
index 00000000..9e91f390
--- /dev/null
+++ b/elements/unmaintained/ntpd/ntpd.bst
@@ -0,0 +1,58 @@
+kind: autotools
+depends:
+- foundation.bst
+sources:
+- kind: git
+  url: upstream:ntp
+  track: ntp-4.2.8p2
+  ref: b2ccf8dd31d1457ae9f0ae270054117179220370
+config:
+  configure-commands:
+  - ./configure --prefix="%{prefix}" --enable-linuxcaps
+  install-commands:
+    (>):
+    - |
+      cat > ntpd.service << EOF
+      [Unit]
+      Description=Network Time Service
+      After=network.target nss-lookup.target
+      Conflicts=systemd-timesyncd.service
+
+      [Service]
+      Type=forking
+      ExecStart=/usr/bin/ntpd -u ntp:ntp -Ng
+      PrivateTmp=True
+      Restart=on-failure
+
+      [Install]
+      WantedBy=multi-user.target
+      EOF
+    - install -D -m 644 ntpd.service "%{install-root}"/lib/systemd/system/ntpd.service
+    - mkdir -p "%{install-root}"/lib/systemd/system/multi-user.target.wants
+    - ln -s /lib/systemd/system/ntpd.service  "%{install-root}"/lib/systemd/system/multi-user.target.wants/ntpd.service
+    - |
+      cat > ntp.conf << EOF
+      # We use iburst here to reduce the potential initial delay to set the clock
+      server 0.pool.ntp.org iburst
+      server 1.pool.ntp.org iburst
+      server 2.pool.ntp.org iburst
+      server 3.pool.ntp.org iburst
+
+      # kod - notify client when packets are denied service,
+      # rather than just dropping the packets
+      #
+      # nomodify - deny queries which attempt to modify the state of the server
+      #
+      # notrap - decline to provide mode 6 control message trap service to
+      # matching hosts
+      #
+      # see ntp.conf(5) for more details
+      restrict -4 default limit kod notrap nomodify
+      restrict -6 default limit kod notrap nomodify
+      EOF
+    - install -D -m 644 ntp.conf "%{install-root}"/etc/ntp.conf
+public:
+  bst:
+    integration-commands:
+    - groupadd -r ntp
+    - useradd -g ntp -d /home/ntp -s /bin/false -r ntp
-- 
cgit v1.2.1

