Modification : vm_hosted : insserv -> runit .
[lhc/ateliers.git] / etc / sv / postgrey / run
diff --git a/etc/sv/postgrey/run b/etc/sv/postgrey/run
new file mode 100755 (executable)
index 0000000..fba506a
--- /dev/null
@@ -0,0 +1,12 @@
+#!/bin/sh -eux
+exec 2>&1
+sv=${PWD#/etc/sv/}
+exec /usr/bin/chpst \
+ -u "$sv":"$sv" \
+ /usr/sbin/postgrey \
+ --auto-whitelist-clients=5 \
+ --dbdir=/var/lib/postgrey \
+ --delay=65 \
+ --max-age=35 \
+ --privacy \
+ --unix=/run/postgrey/socket