This is a fun exercise :)All right. Let us first analyze what the requirements should be. Obviously I am assuming a lot of things and thinking about this in a way I would go about building a (minimal)forum on raspberry pi:-
1. There should be a couple of predefined categories.
2. There should be a way to authenticate/authorize users.
3. There should be a way to search the previous posts.
4. There should be a facility to moderate.
Static forums
Very neat idea. All we need is a simple webserver, I am thinking, nginx that transforms and renders our posts to a user. Our first requirement that of predefined categories can be easily met by creating sub directories inside the directory that will be served. And we can avoid duplicating the pages between the sub directory (ie. a tag) and the main directory by using symbolic links[1] and configuring nginx to serve the symlinks [2]. Moderation of posts can be done by migrating a post in and our of a `moderate` folder that is not served by the application. But that obviously limits the moderation only to the webmaster. The trouble arises in two cases
a) When we need a facility to manage sessions. There is no way we can do that in static pages.
b) It will be quite difficult to create a search index for our application.
Now nginx is a good choice as it is pretty light weight and we will keep it. But what if we could have another application that can easily talk with nginx, manage user authentication for us, allow us to create search indexes, takes care of our data and still be light weight. Other have already suggested sqllite.How about couchdb?[3]
First couchdb has built in authentication and authorzation support. It will take you no more than 3 http requests to implement your own register-login-logout-scenario[4]. Second it is pretty easy creating simple search indexes with couchdb[5]. You can serve your forum directly from couchdb. It does not statisfy your orignal requirement of no database but it certainly gives you a way to work without any application layer. But perhaps most importantly it is very low on memory consumption. Not as low as sql lite but still quite low.
[1](http://stackoverflow.com/questions/1951742/how-to-symlink-a-...)
[2](http://nginx.org/en/docs/http/ngx_http_core_module.html#disa...)
[3](http://couchdb.apache.org/)
[4](http://www.staticshin.com/programming/easy-user-accounts-man...)
[5](http://wiki.apache.org/couchdb/View_collation#String_Ranges)