You are not logged in.
Any chance someone could create a package for the Tiny http server, thttpd, available from:
http://www.acme.com/software/thttpd/
Thanks.
Offline
I also would like to see that package. 8)
Offline
what about a really big one? roxen: http://www.roxen.com/products/webserver/
(i experimented with it on a older SuSE installation - it is really huge)
no, seriously: thttpd is really usefull --- maybe i have some time this weekend ;-)
The impossible missions are the only ones which succeed.
Offline
Anyone?
Offline
Offline
i cannot watch people being sad ... here:
# $Id: $
# Maintainter: Damir Perisa <damir.perisa@bluewin.ch>
pkgname=thttpd
pkgver=2.25b
pkgrel=1
pkgdesc="tiny/turbo/throttling HTTP server"
url="http://www.acme.com/software/thttpd/"
source=($url/$pkgname-$pkgver.tar.gz)
build() {
cd $startdir/src/$pkgname-$pkgver
./configure --prefix=/usr
make || return 1
mkdir -p $startdir/pkg/usr/man/man1/
make prefix=$startdir/pkg/usr WEBGROUP=root install || return 1
# install -D -m755 ../thttpd $startdir/pkg/etc/rc.d/thttpd
}
only thing:
/etc/rc.d/thttpd do not yet exist ... anyone to write one?
The impossible missions are the only ones which succeed.
Offline
bah not tested... I wrote this out in the forums and not on my linux box, so if it fails, then screw with it... i'll just provide a skeleton
#!/bin/bash
. /etc/rc.conf
. /etc/rc.d/functions
case "$1" in
start)
stat_busy "Starting thttpd"
/usr/local/sbin/thttpd -D -C /usr/local/www/thttpd_config
if [ $? -gt 0 ]; then
stat_fail
else
add_daemon thttpd
stat_done
fi
;;
stop)
stat_busy "Stopping thttpd"
killall thttpd
if [ $? -gt 0 ]; then
stat_fail
else
rm_daemon thttpd
stat_done
fi
;;
restart)
$0 stop
sleep 1
$0 start
;;
*)
echo "Usage $0 {start|stop|restart}"
;;
esac
and the config file: /usr/local/www/thttpd_config
dir=/usr/local/www/data
chroot
cgipat=**.cgi
logfile=/usr/local/www/logs/thttpd_log
pidfile=/var/run/thttpd.pid
Offline
bah not tested... I wrote this out in the forums and not on my linux box, so if it fails, then screw with it... i'll just provide a skeleton
#!/bin/bash . /etc/rc.conf . /etc/rc.d/functions case "$1" in start) stat_busy "Starting thttpd" /usr/local/sbin/thttpd -D -C /usr/local/www/thttpd_config if [ $? -gt 0 ]; then stat_fail else add_daemon thttpd stat_done fi ;; stop) stat_busy "Stopping thttpd" killall thttpd if [ $? -gt 0 ]; then stat_fail else rm_daemon thttpd stat_done fi ;; restart) $0 stop sleep 1 $0 start ;; *) echo "Usage $0 {start|stop|restart}" ;; esac
and the config file: /usr/local/www/thttpd_config
dir=/usr/local/www/data chroot cgipat=**.cgi logfile=/usr/local/www/logs/thttpd_log pidfile=/var/run/thttpd.pid
replace /usr/local/ by /usr/ and these should be ok
thanx
PS
"bah" is overrated ;-)
The impossible missions are the only ones which succeed.
Offline
thttpd-2.25b-1 -> testing
give it a try and report your success/failure with it
The impossible missions are the only ones which succeed.
Offline
dp & phrakture, first of all thanks
Now I grabbed the package from testing and installed it.
it didn't work and it complained on starting thttpd
mkdir /usr/www/logs
mkdir /usr/www/data
fixed it a bit. but now I get this:
$ sudo /etc/rc.d/thttpd start
:: Starting thttpd [BUSY] /usr/sbin/thttpd: logfile is not within the chroot tree, you will not be able to re-open it
Offline
Offline
grabbed the package from testing
$ pacman -Ql thttpd
thttpd /etc/
thttpd /etc/rc.d/
thttpd /etc/rc.d/thttpd
thttpd /usr/
thttpd /usr/man/
thttpd /usr/man/man1/
thttpd /usr/man/man1/htpasswd.1.gz
thttpd /usr/man/man1/makeweb.1.gz
thttpd /usr/man/man8/
thttpd /usr/man/man8/redirect.8.gz
thttpd /usr/man/man8/ssi.8.gz
thttpd /usr/man/man8/syslogtocern.8.gz
thttpd /usr/man/man8/thttpd.8.gz
thttpd /usr/sbin/
thttpd /usr/sbin/htpasswd
thttpd /usr/sbin/makeweb
thttpd /usr/sbin/syslogtocern
thttpd /usr/sbin/thttpd
thttpd /usr/www/
thttpd /usr/www/cgi-bin/
thttpd /usr/www/cgi-bin/phf
thttpd /usr/www/cgi-bin/redirect
thttpd /usr/www/cgi-bin/ssi
thttpd /usr/www/thttpd_config
also made those 2 dirs or else it could complain
but now it also complains
I must be missing sth, and I will not be the only one, so it would be wise to put an echo in the package on what to do next, if we're supposed to do something more
thanks again
Offline
thttpd-2.25b-1t2 is out:
changes:
- added missing dir /usr/www/data
- changed logs to be under /var/log/thttpd/
by the way:
thttpd: /usr/man/man1/htpasswd.1.gz: owned by apache
thttpd: /usr/sbin/htpasswd: owned by apache
it seems that apache conflicts with thttpd in this files --- diff says that they are not the identical --- anybody knows more about the difference of them?
The impossible missions are the only ones which succeed.
Offline
still the same here..
$ sudo /etc/rc.d/thttpd start
:: Starting thttpd [BUSY] /usr/sbin/thttpd: logfile is not within the chroot tree, you will not be able to re-open it
Offline
still the same here..
$ sudo /etc/rc.d/thttpd start
:: Starting thttpd [BUSY] /usr/sbin/thttpd: logfile is not within the chroot tree, you will not be able to re-open it
i was not thinking while making 1t2 .... argh!
thttpd wants the log to be in the chroot? ok, let's do exactly that:
logfile=/usr/www/data/log/thttpd_log
1t3 is out and let's hope i was more concentrated this time :oops:
The impossible missions are the only ones which succeed.
Offline
well
$ sudo /etc/rc.d/thttpd start
:: Starting thttpd [BUSY]
nothing else happens [i have to kill it]
d_tidptr=0xb7e9a4a8) = 15009
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
rt_sigaction(SIGINT, {0x80789f0, [], 0}, {SIG_DFL}, 8) = 0
waitpid(-1,
so I'm guessing sth with the 'return' value that won't make it pass thru and it sticks to Busy because other than that it seems to work fine
Offline
well
$ sudo /etc/rc.d/thttpd start
:: Starting thttpd [BUSY]nothing else happens [i have to kill it]
d_tidptr=0xb7e9a4a8) = 15009
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
rt_sigaction(SIGINT, {0x80789f0, [], 0}, {SIG_DFL}, 8) = 0
waitpid(-1,so I'm guessing sth with the 'return' value that won't make it pass thru and it sticks to Busy because other than that it seems to work fine
just wondering: do you have some files under /usr/www/data? else, the server has nothing to offer, if i understand it right
thttpd comes really "tiny" and has no default dummy html file for the start
The impossible missions are the only ones which succeed.
Offline
again the server works but it will freeze saying BUSY. try it yourself and you'll see.
$ pwd
/usr/www/data
[nk@Freud data]$ ls
foo foo.html log
$ su
Password:
[root@Freud data]# /etc/rc.d/thttpd start
:: Starting thttpd [BUSY]
Offline
again the server works but it will freeze saying BUSY. try it yourself and you'll see.
$ pwd
/usr/www/data
[nk@Freud data]$ ls
foo foo.html log
$ su
Password:
[root@Freud data]# /etc/rc.d/thttpd start
:: Starting thttpd [BUSY]
the server works for you, but simply the /etc/rc.d/thttpd keeps being [busy]? sorry, that i didn't understand this the first time
i tried to run thttpd by hand and not from the rc.d script, sorry - i trusted that phrakture made it right
ok: 1t5 is out and i removed "-D" that hinders thttpd to become daemon ... see more info here:
http://www.acme.com/software/thttpd/thttpd_man.html
The impossible missions are the only ones which succeed.
Offline
well by removing -D we have these problems:
sudo /etc/rc.d/thttpd start
:: Starting thttpd [DONE]
[nk@Freud ~]$ sudo /etc/rc.d/thttpd restart
:: Stopping thttpd [BUSY] Terminated
-D works fine, but
if [ $? -gt 0 ]; then
stat_fail
else
add_daemon thttpd
stat_done
don't seem to be the correct, cause eventhough the app seems to run ok, it keeps saying busy
Offline
sorry about that - like i said i didnt test it...
#!/bin/bash
. /etc/rc.conf
. /etc/rc.d/functions
PID=`pidof -o %PPID /usr/local/sbin/thttpd`
case "$1" in
start)
stat_busy "Starting thttpd"
/usr/local/sbin/thttpd -C /usr/local/www/thttpd_config
if [ $? -gt 0 ]; then
stat_fail
else
add_daemon thttpd
stat_done
fi
;;
stop)
stat_busy "Stopping thttpd"
[ ! -z "$PID" ] && kill $PID &>/dev/null
if [ $? -gt 0 ]; then
stat_fail
else
rm_daemon thttpd
stat_done
fi
;;
restart)
$0 stop
sleep 1
$0 start
;;
*)
echo "Usage $0 {start|stop|restart}"
;;
esac
and the config file: /usr/local/www/thttpd_config
dir=/usr/local/www/data
chroot
cgipat=**.cgi
logfile=/usr/local/www/logs/thttpd_log
pidfile=/var/run/thttpd.pid
[/quote]
Offline
it now works.
dp plz update the pkg, of course remove the /local stuff
Offline
very sorry, i totally forgot this thread :oops: (evolutive genetics is soooo cool!!!)
i'll update it asap - thanx for reminder
The impossible missions are the only ones which succeed.
Offline