# Set up htwtxt environment.
apt-get -y install screen nginx
apt-get -y -t jessie-backports install golang
- su - plom -c 'git clone '\
-'https://github.com/plomlompom/htwtxt $GOPATH/src/htwtxt'
+ su - plom -c 'git clone https://github.com/plomlompom/htwtxt $GOPATH/src/htwtxt'
su - plom -c 'go get htwtxt'
path=`su - plom -c 'echo $GOPATH/bin/htwtxt'`
#setcap 'cap_net_bind_service=+ep' $path
cp config/systemfiles/plomlombot.service \
/etc/systemd/system/plomlombot.service
systemctl enable /etc/systemd/system/plomlombot.service
+ mkdir /var/www/irclogs_zrolaps/
+ touch /var/www/password_irclogs_zrolaps
fi
elif [ "$1" = "thinkpad" ]; then
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
- # file server
+ # IRC logs server
server {
location / {
+ auth_basic "IRC logs";
+ auth_basic_user_file /var/www/password_irclogs_zrolaps;
autoindex on;
- root /data/www;
+ root /var/www/irclogs_zrolaps/;
}
}
# htwtxt
server {
- listen 8080;
- #server_name htwtxt.plomlompom.com;
+ server_name htwtxt.plomlompom.com;
location / {
proxy_pass http://127.0.0.1:8000;
}