summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorpavel <pavel.github@outlook.com>2016-04-09 06:37:12 -0400
committerpavel <pavel.github@outlook.com>2016-04-09 06:37:12 -0400
commit7c0958c614591ce69490af74f9f530d71805dc85 (patch)
treec28f7dab51abfa14d2c9e8f2249db11c4f8da8f0 /system
parentbc443e594fe0faf597d690c9f8c03aefaae35a84 (diff)
Removed 'netdata' folder in service files
Diffstat (limited to 'system')
-rwxr-xr-xsystem/netdata-openrc.in7
-rw-r--r--system/netdata.service.in5
2 files changed, 3 insertions, 9 deletions
diff --git a/system/netdata-openrc.in b/system/netdata-openrc.in
index 3b747fcba1..f59955015f 100755
--- a/system/netdata-openrc.in
+++ b/system/netdata-openrc.in
@@ -22,7 +22,7 @@
: ${NETDATA_START_AFTER_SERVICES:=apache2 squid nginx mysql named opensips upsd hostapd postfix lm_sensors}
extra_started_commands="getconf"
-pidfile="/run/netdata/netdata.pid"
+pidfile="/run/netdata.pid"
command="${NETDATA_INSTALL_PATH}/usr/sbin/netdata"
command_background="yes"
command_args="-pidfile ${pidfile} ${NETDATA_EXTRA_ARGS}"
@@ -36,11 +36,6 @@ depend() {
checkpath -o ${NETDATA_OWNER} -d @localstatedir_POST@/cache/netdata /run/netdata
}
-start_pre() {
- piddir=$(dirname ${pidfile})
- mkdir -p ${piddir}
-}
-
start_post() {
if [[ ! -f @sysconfdir_POST@/netdata/netdata.conf ]]; then
ebegin "Downloading default configuration to @sysconfdir_POST@/netdata/netdata.conf"
diff --git a/system/netdata.service.in b/system/netdata.service.in
index fc5866c5a6..e26068d289 100644
--- a/system/netdata.service.in
+++ b/system/netdata.service.in
@@ -7,9 +7,8 @@ Type=forking
WorkingDirectory=/tmp
User=root
Group=root
-PIDFile=@localstatedir_POST@/run/netdata/netdata.pid
-ExecStartPre=/usr/bin/mkdir -p @localstatedir_POST@/run/netdata
-ExecStart=@sbindir_POST@/netdata -pidfile @localstatedir_POST@/run/netdata/netdata.pid
+PIDFile=@localstatedir_POST@/run/netdata.pid
+ExecStart=@sbindir_POST@/netdata -pidfile @localstatedir_POST@/run/netdata.pid
ExecStop=/bin/kill -SIGTERM $MAINPID
TimeoutStopSec=30