Move torrent web files to more standard /srv/web dir and adjust scripts
This commit is contained in:
parent
98dbde496c
commit
cd5e0996b4
5 changed files with 13 additions and 12 deletions
|
@ -2,7 +2,7 @@
|
|||
|
||||
statscmd=/usr/local/bin/torrent-data.py
|
||||
btdata=/srv/torrent/data/bttrack.dat
|
||||
outputdir=/srv/torrent/www/stats/
|
||||
outputdir=/srv/web/stats/
|
||||
hourlydir=$outputdir/hourly
|
||||
dailydir=$outputdir/daily
|
||||
latestlink=$outputdir/current-stats.json
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
# If no listen option is given (here or on the command line), opentracker
|
||||
# listens on 0.0.0.0:6969 tcp and udp.
|
||||
#
|
||||
listen.tcp_udp 152.19.134.141
|
||||
# listen.tcp_udp 0.0.0.0
|
||||
# listen.tcp_udp 192.168.0.1:80
|
||||
# listen.tcp_udp 10.0.0.5:6969
|
||||
|
@ -42,7 +43,7 @@ access.whitelist ./whitelist
|
|||
#
|
||||
access.stats 98.122.179.19
|
||||
access.stats 127.0.0.1
|
||||
access.stats 152.19.134.148
|
||||
access.stats 152.19.134.141
|
||||
#
|
||||
# There is another way of hiding your stats. You can obfuscate the path
|
||||
# to them. Normally it is located at /stats but you can configure it to
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
# fetch data files from the opentracker stats output
|
||||
# store them away for later analysis
|
||||
# skvidal
|
||||
base=/srv/torrent/www/stats/raw
|
||||
base=/srv/web/stats/raw
|
||||
baseurl='http://torrent.fedoraproject.org:6969/stats?mode='
|
||||
date=`date +%Y-%m-%d`
|
||||
hour=`date +%H`
|
||||
|
@ -29,10 +29,10 @@ ln -sf $dest/$hour.xml $base/everything/current.xml
|
|||
|
||||
# generate the json files
|
||||
hourdate=`date +%Y-%m-%d-%H-%M`
|
||||
/usr/local/bin/torrentjsonstats.py $base/torrent/current.txt > /srv/torrent/www/stats/hourly/torrent-stats-$hourdate.json
|
||||
ln -sf /srv/torrent/www/stats/hourly/torrent-stats-$hourdate.json /srv/torrent/www/stats/current-stats.json
|
||||
/usr/local/bin/torrentjsonstats.py $base/torrent/current.txt > /srv/web/stats/hourly/torrent-stats-$hourdate.json
|
||||
ln -sf /srv/torrent/www/stats/hourly/torrent-stats-$hourdate.json /srv/web/stats/current-stats.json
|
||||
|
||||
if [ $hour == '12' ]; then
|
||||
/usr/local/bin/torrentjsonstats.py $base/torrent/current.txt > /srv/torrent/www/stats/daily/torrent-stats-$date.json
|
||||
/usr/local/bin/torrentjsonstats.py $base/torrent/current.txt > /srv/web/stats/daily/torrent-stats-$date.json
|
||||
fi
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<Directory "/srv/torrent/www">
|
||||
<Directory "/srv/web">
|
||||
Options Indexes FollowSymLinks
|
||||
Require all granted
|
||||
</Directory>
|
||||
|
|
|
@ -25,11 +25,11 @@
|
|||
file: path={{ item.file }} owner={{ item.owner }}
|
||||
group={{ item.group }} mode={{ item.mode }} state=directory
|
||||
with_items:
|
||||
- { file: /srv/torrent/www/stats/daily/, owner: opentracker, group: torrent, mode: 2775}
|
||||
- { file: /srv/torrent/www/stats/hourly/, owner: opentracker, group: torrent, mode: 2775}
|
||||
- { file: /srv/torrent/www/stats/raw/, owner: opentracker, group: torrentadmin, mode: 2775}
|
||||
- { file: /srv/torrent/www/stats/raw/evertyhing/, owner: opentracker, group: torrentadmin, mode: 2775}
|
||||
- { file: /srv/torrent/www/stats/raw/torrent/, owner: opentracker, group: torrentadmin, mode: 2775}
|
||||
- { file: /srv/web/stats/daily/, owner: opentracker, group: torrent, mode: 2775}
|
||||
- { file: /srv/web/stats/hourly/, owner: opentracker, group: torrent, mode: 2775}
|
||||
- { file: /srv/web/stats/raw/, owner: opentracker, group: torrentadmin, mode: 2775}
|
||||
- { file: /srv/web/stats/raw/evertyhing/, owner: opentracker, group: torrentadmin, mode: 2775}
|
||||
- { file: /srv/web/stats/raw/torrent/, owner: opentracker, group: torrentadmin, mode: 2775}
|
||||
tags:
|
||||
- config
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue