[Seaside] Fast Production Pier

Lukas Renggli renggli at gmail.com
Wed Feb 22 23:46:20 UTC 2006

> > 2. The setup on my own gentoo linux looks slightly more complicated.
> > First of all I use daemon-tools <http://cr.yp.to/daemontools.html> to
> > make sure the image runs all the time. The startup-script looks like:
> >
> >       #!/bin/sh
> >       exec \
> >               nice \
> >               setuidgid apache \
> >               squeak -vm-sound-null -vm-display-null pier.image
> >
> Lukas & All,
> where do you usually place your squeak image in the directory tree? Is
> it under /var/www/ ?
> And, who is running your bash script above? /etc/rc.local?

I am using the daemon-tools, a powerful replacement to rc.local,
inittab, init.d, and friends. It is like a super-daemon that controls
a set of daemons and ensures that they run all the time.

So for the setup I followed the directory structure suggested as by
the daemon-tools:

/service -- all daemon-tools daemons should be in here
/service/app  -- my application directory
/service/app/pier.image -- the image of question (could be also put
anywhere else)
/service/app/run -- the run-script as shown above

That's it, all the rest happens automatically: your image will be
immediately started after creating the run-script, it will be executed
upon system-startup, and if your image crashes it will be immediately
re-started, etc.

I like that setup, because it is much easier than to fiddle around
with init-scripts, broken pid-files, images that have been started
1000 times, ...


Lukas Renggli

More information about the Seaside mailing list