Add PID file support and --background, --foreground, --help flags to httpd.js