From 2d386439d73942edf2ab74f9fb3c1d0231819170 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Wed, 15 Dec 2010 22:45:02 +0100 Subject: optimize init script and config --- package/tor/files/tor.init | 4 ++-- package/tor/files/torrc | 12 ++---------- 2 files changed, 4 insertions(+), 12 deletions(-) (limited to 'package/tor') diff --git a/package/tor/files/tor.init b/package/tor/files/tor.init index cbc395726..5bcca701a 100644 --- a/package/tor/files/tor.init +++ b/package/tor/files/tor.init @@ -11,9 +11,9 @@ autostart) exec sh $0 start ;; start) - [ -d /var/log/tor ] || mkdir -p /var/log/tor + [ -d /var/run/tor ] || mkdir -p /var/run/tor [ -d /tmp/.tor ] || mkdir -p /tmp/.tor - chown tor:tor /tmp/.tor + chown tor:tor /tmp/.tor /var/run/tor su - tor -c tor ;; stop) diff --git a/package/tor/files/torrc b/package/tor/files/torrc index 3a46e8933..b533ce04c 100644 --- a/package/tor/files/torrc +++ b/package/tor/files/torrc @@ -1,15 +1,7 @@ ## Configuration file for a typical tor user -## Built for Tor version 0.1.0.8-rc -## (May or may not work for older or newer versions of Tor.) # # On Unix, Tor will look for this file in someplace like "~/.tor/torrc" or # "/etc/torrc" -# -# On Windows, Tor will look for the configuration file in someplace like -# "Application Data\tor\torrc" or "Application Data\\tor\torrc" -# -# With the default Mac OS X installer, Tor will look in ~/.tor/torrc or -# /Library/Tor/torrc ## Replace this with "SocksPort 0" if you plan to run Tor only as a @@ -40,7 +32,7 @@ AllowUnverifiedNodes middle,rendezvous ## Send ONLY debug messages to /var/log/tor/debug.log #Log debug-debug file /var/log/tor/debug.log ## To use the system log instead of Tor's logfiles, uncomment these lines: -#Log notice syslog +Log notice syslog ## To send all messages to stderr: #Log debug stderr @@ -131,4 +123,4 @@ RunAsDaemon 1 #ExitPolicy accept *:119 # accept nntp as well as default exit policy #ExitPolicy reject *:* # middleman only -- no exits allowed -PidFile /var/run/tor.pid +PidFile /var/run/tor/tor.pid -- cgit v1.2.3