-
Notifications
You must be signed in to change notification settings - Fork 1
/
INSTALL
41 lines (32 loc) · 1.63 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
These are really basic instructions, but they should help.
First, requirements:
1) PostgreSQL
2) Lighttpd (or Apache 2)
3) PHP:
You need these modules: PDO, PDO PgSQL, Hash, Memcache, Tokenizer
PEAR modules: Auth/OpenID
4) Memcached
To install the software, place it into a web directory, and then configure lighttpd
with the rewrite rules needed:
server.document-root = "/web/pastebin.ca/htdocs"
accesslog.filename = var.logdir + "/pastebin.ca-access.log"
dir-listing.activate = "disable"
url.rewrite = (
"^/([0-9]+)([,'\".;]+)(\?.*)?" => "/$1$3",
"^/([0-9]+)(\.html?)?$" => "/index.php?id=$1",
"^/([0-9]+)(\.html?)?\?(.*)$" => "/index.php?id=$1&$3",
"^/([A-Z][0-9a-zA-Z-]{5,8})([,'\".;]+)(\?.*)?" => "/$1$3",
"^/([A-Z][0-9a-zA-Z-]{5,8})(\.html?)?$" => "/index.php?mask=$1",
"^/([A-Z][0-9a-zA-Z-]{5,8})(\.html?)?\?(.*)$" => "/index.php?mask=$1&$3",
"^/new(\.html?|\.php)?$" => "/index.php?a=n",
"^/archives?([0-9]+)(\.html?)?$" => "/archives.php?page=$1",
"^/tree([0-9]+)(\.html?|\.php)?$" => "/tree.php?tree=$1",
"^/desc([0-9]+)(\.html?|\.php)?$" => "/tree.php?id=$1",
"^/raw/([0-9]+)(\.html?|\.txt)?$" => "/raw.php/$1",
"^/rss/(.*)$" => "/rss.php/$1",
"^/download/(.*)$" => "/download.php/$1"
)
server.error-handler-404 = "/error404.php"
Configuration:
1) Copy localsettings.inc.php.sample to localsettings.inc.php in the htdocs/include/ directory
2) Customize these values to your server