1
0
Fork 0
mirror of https://github.com/dirtbags/moth.git synced 2025-01-07 04:20:39 -07:00
moth/packages/mcp/service/httpd/run
2011-03-03 20:46:50 -07:00

24 lines
385 B
Bash
Executable file

#! /bin/sh
exec 2>&1
install -d /var/www
# Link in puzzles and web pages
for d in /opt/*; do
if [ -d $d/puzzles ]; then
ln -sf $d/puzzles /var/www/$(basename $d)
fi
if [ -d $d/www ]; then
ln -sf $d/www/* /var/www/
fi
done
cd /var/www
exec thttpd -D \
-h 10.0.0.2 \
-c "**.cgi" \
-u ctf \
-l /proc/self/fd/1 \
-T UTF-8 \
-nos