Aug 22, 2011


Hacking on Act

As you may have heard, we’ve finished the first part of converting Act to run on PSGI. Other than modernizing Act a bit, it has the added benefit of lowering the barrier to entry for working on Act. However, the docs haven’t been updated yet, so you may be wondering exactly how to set it up in a working state.

Setting up the database

I’ll assume you know how to set up a PostgreSQL server. After you’ve done so, run the following commands on your favorite shell (assuming PostgreSQL is running on localhost):

createuser act -D -R -S
for db in act{,test,wiki}; do
 createdb $db -O act --encoding=UTF8
done

bin/dbinit | psql -U act act # this will spit out some "errors"; don't worry!
bin/dbinit | psql -U act actest
wiki-toolkit-setupdb --type postgres --name actwiki --user act

Obviously, this isn’t the most secure setup, but it’ll be okay for development.

Copying over static files

cp -R skel/actdocs/static .

Creating the configuration file

mkdir conf/

Now create a file conf/act.ini. If you’re looking for a quick start (which I presume you are), you can base your configuration off of my template here.

Setting the environment

One last thing to do before we’re ready:

export ACTHOME=$(pwd)

Plackup!

This part’s easy:

plackup

Now you can talk to Act on http://localhost:5000!