summaryrefslogtreecommitdiffhomepage
path: root/pkg/deb/debian
diff options
context:
space:
mode:
authorAndrei Belov <defan@nginx.com>2019-10-03 17:46:28 +0300
committerAndrei Belov <defan@nginx.com>2019-10-03 17:46:28 +0300
commit3dd3f861f4c3aa320aa137802f033f8f1fc7dc41 (patch)
tree357577c560920eb0f5837b7d073999f5c7a1a2cd /pkg/deb/debian
parent9de7aea721245cda9f079a2b29d8efaf99c440fd (diff)
parent59db9a3887211fccdaec04b7952ad0140090de22 (diff)
downloadunit-3dd3f861f4c3aa320aa137802f033f8f1fc7dc41.tar.gz
unit-3dd3f861f4c3aa320aa137802f033f8f1fc7dc41.tar.bz2
Merged with the default branch.
Diffstat (limited to '')
-rw-r--r--pkg/deb/debian/unit.init4
-rw-r--r--pkg/deb/debian/unit.logrotate15
2 files changed, 16 insertions, 3 deletions
diff --git a/pkg/deb/debian/unit.init b/pkg/deb/debian/unit.init
index 2f573f99..900e97fd 100644
--- a/pkg/deb/debian/unit.init
+++ b/pkg/deb/debian/unit.init
@@ -13,11 +13,9 @@
### END INIT INFO
PATH=/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/sbin/unitd
-NAME=unitd
+NAME=unit
DESC=unitd
-[ -r /etc/default/${NAME} ] && . /etc/default/${NAME}
-
#includes lsb functions
. /lib/lsb/init-functions
diff --git a/pkg/deb/debian/unit.logrotate b/pkg/deb/debian/unit.logrotate
new file mode 100644
index 00000000..416947ca
--- /dev/null
+++ b/pkg/deb/debian/unit.logrotate
@@ -0,0 +1,15 @@
+/var/log/unit.log {
+ daily
+ missingok
+ rotate 7
+ compress
+ delaycompress
+ nocreate
+ notifempty
+ su root root
+ postrotate
+ if [ -f /var/run/unit.pid ]; then
+ /bin/kill -SIGUSR1 `cat /var/run/unit.pid`
+ fi
+ endscript
+}