Instaweb : Instant Web Publishing Tool

Instaweb : Instant Web Publishing Tool

By Noel Welsh (noelwelsh at yahoo dot com) 

This manual documents Instaweb version 1.3
Time-stamp: <06/05/30 14:47:33 noel>

Keywords: _instaweb_, _servlet_, _internet_, _web_


Instaweb is a simple tool that makes it easier to run
servlets in the PLT web server.

It does the following:

  - configures the web server to run a single servlet

  - runs the web server in a handy interactive shell


Simply require the instaweb library, and call the function
instaweb with the name of the servlet you want to run, and
optionally the port number and IP address to listen on.  If
the IP address is #f or not given the server will listen on
all addresses.  The servlet must be in the current


  (require (planet "" ("schematics" "instaweb.plt")))
  (instaweb "" 5678 "")

> instaweb : string [integer] [(U string #f)] -> void

The file name of the servlet 

The optional port to listen on, defaults to 80

The optional IP address to listen on, or #f (the default)
for all addresses


The web server requires servlets live in a directory called
servlets.  Hence instaweb creates this directory and copies
your servlet to it.  This means if your servlet requires any
modules using relative paths those modules probably won't be
found.  To get around this put your support modules into a
collection that you install via a .plt or Planet.  Then
require them with the (lib ...)  or (planet ...) form as

Instaweb doesn't clean up after itself.  This is a
deliberate decision as you'll probably want to populate the
web root directories with static files etc. over time.


Eric Hanchow, for pointing out documentation typos