I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Unverified Commit d7fdd6d9 authored by idk's avatar idk Committed by GitHub
Browse files

Merge pull request #24 from kfeoktistoff/debian_mkdir_log_on_startup

debian: create a log dir on startup if absent
parents 5a3a7b84 e06f8961
No related branches found
No related tags found
No related merge requests found
...@@ -96,6 +96,7 @@ do_start() ...@@ -96,6 +96,7 @@ do_start()
|| return 1 || return 1
[ -d $RUN ] || mkdir $RUN > /dev/null 2>&1 [ -d $RUN ] || mkdir $RUN > /dev/null 2>&1
[ -d $I2PTEMP ] || mkdir $I2PTEMP > /dev/null 2>&1 [ -d $I2PTEMP ] || mkdir $I2PTEMP > /dev/null 2>&1
[ -d "/var/log/$NAME" ] || mkdir "/var/log/$NAME" > /dev/null 2>&1
if [ -r $PIDFILE ]; then if [ -r $PIDFILE ]; then
PID="$(cat ${PIDFILE})" PID="$(cat ${PIDFILE})"
if ! kill -0 $PID > /dev/null 2>&1; then if ! kill -0 $PID > /dev/null 2>&1; then
......
...@@ -39,6 +39,7 @@ User=i2psvc ...@@ -39,6 +39,7 @@ User=i2psvc
PermissionsStartOnly=true PermissionsStartOnly=true
AppArmorProfile=system_i2p AppArmorProfile=system_i2p
ExecStartPre=/bin/mkdir -p /tmp/i2p-daemon ExecStartPre=/bin/mkdir -p /tmp/i2p-daemon
ExecStartPre=/bin/mkdir -p /var/log/i2p
ExecStartPre=/bin/chown -R ${I2PUSER}:${I2PUSER} /var/log/i2p /run/i2p /tmp/i2p-daemon ExecStartPre=/bin/chown -R ${I2PUSER}:${I2PUSER} /var/log/i2p /run/i2p /tmp/i2p-daemon
ExecStartPre=/bin/chmod 750 /var/log/i2p ExecStartPre=/bin/chmod 750 /var/log/i2p
ExecStart=/usr/sbin/wrapper "$I2P_ARGS" ExecStart=/usr/sbin/wrapper "$I2P_ARGS"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment