From 3118910d271bdb38673c8ee90534dec5482af0a1 Mon Sep 17 00:00:00 2001 From: ale <ale@incal.net> Date: Sat, 9 Nov 2013 11:53:37 +0000 Subject: [PATCH] use pseudo-standard service directory --- debian/postinst | 4 ++-- debian/rules | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/debian/postinst b/debian/postinst index 5992a913..b09c0f19 100644 --- a/debian/postinst +++ b/debian/postinst @@ -19,7 +19,7 @@ set -e create_users() { - if ! getent passwd log 2>/dev/null ; then + if ! getent passwd log >/dev/null ; then adduser --system --home /var/log --no-create-home --group log fi } @@ -35,7 +35,7 @@ create_log_dir() { activate_services() { for svc in $@ ; do test -e /etc/service/$svc \ - || ln -s /etc/radioai/svc/$svc /etc/service/$svc + || ln -s /etc/svc/$svc /etc/service/$svc done } diff --git a/debian/rules b/debian/rules index 926be2ac..528eedfa 100755 --- a/debian/rules +++ b/debian/rules @@ -19,7 +19,7 @@ export DH_OPTIONS GOPKG = git.autistici.org/ale/radioai DESTDIR = $(CURDIR)/debian/radioai -SVCDIR = $(DESTDIR)/etc/radioai/svc +SVCDIR = $(DESTDIR)/etc/svc %: dh $@ @@ -46,8 +46,8 @@ override_dh_install: install -d -o root -g root $(SVCDIR)/$$f/log ; \ install -m 755 -o root -g root debian/services/$$f \ $(SVCDIR)/$$f/run ; \ - chmod 0755 $(SVCDIR)/$$f/log/run ; \ echo -e '#!/bin/sh\nexec chpst -u log svlogd -tt /var/log/radioai/'$$f > \ $(SVCDIR)/$$f/log/run ; \ + chmod 0755 $(SVCDIR)/$$f/log/run ; \ done) -- GitLab