werc Bringing minimalism and sanity to the web

Install werc at Dreamhost

Popular web hosting service Dreamhost does not allow users to modify httpd.conf for their hosted domains. Limited options are enabled for .htaccess files. Below is the method used to configure a working site that ran at Dreamhost.


Install plan9port or 9base in your home directory: /home/username/plan9

Unpack werc into your domain’s directory: /home/username/domain.com

Create a directory for your domain: /home/username/domain.com/werc/sites/domain.com


cp initrc to initrc.local and modify



Modify /home/username/domain.com/werc/bin/werc.rc



Create /home/username/domain.com/werc/bin/werc.cgi

export PLAN9=/home/username/plan9
export PATH=$PLAN9/bin:$PATH
exec ./werc.rc


Create /home/username/domain.com/.htaccess

ReWriteEngine On
<IfModule mod_dir.c>
  DirectoryIndex /werc.cgi

RewriteRule (.*) /home/username/domain.com/werc/sites/%{HTTP_HOST}/$1                                                                           
RewriteCond %{REQUEST_FILENAME} !-f 
RewriteRule .* /home/username/domain.com/werc/bin/werc.cgi

RewriteRule /werc.rc /home/username/domain.com/werc/bin/werc.cgi
ErrorDocument 404 /werc.cgi

To post a comment you need to login first.