-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathREADME
More file actions
79 lines (58 loc) · 2.99 KB
/
README
File metadata and controls
79 lines (58 loc) · 2.99 KB
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
This is the current codebase for DWiki, my Python based wiki-oid engine
that I use for my techblog Wandering Thoughts (among other things),
http://utcc.utoronto.ca/~cks/space/blog/
It is not a completely useful or documented codebase at the moment.
Bits:
- test: hierarchy of basic templates, pages, and so on for testing. It's
also served as the base set of files for my production uses of DWiki.
test/pages/dwiki/ contains various documentation on DWiki's operation.
- wiki.conf: sample / example / testing configuration file
See test/pages/dwiki/ConfigurationFile
- dwiki-serv.py: serve DWiki using Python's built in web server code.
Suitable only for testing.
- dwiki-cgi.py: run DWiki as a CGI.
- dwiki-scgi.py: SCGI-based frontend for DWiki. Its usage is complex,
see -h/--help. It normally communicates with your web server (or
SCGI client) over a Unix domain socket.
- supervise-sock.py: Supervise something, like dwiki-scgi.py, that
supports being passed its server socket through systemd's socket
activation protocol.
- dwiki-cat.py: a relatively raw rendering interface for DWiki.
Mostly suitable for examining the internals and dumping raw pages.
- dpasswd.py: add entries to a DWiki password file. Has bugs about
in-place updates, which should be fixed.
- testbench.py: a timing and profiling test harness. Using statprof
requires some external assistance beyond the scope of this README.
- dwiki-cache.py: force things into the brute-force cache. Note that
you need to set the correct server hostname and possibly the schema
(http vs https) and port or your BFC-forcing will be ineffective.
All four DWiki frontends take a common core of options (in addition
to some options specific to each frontend) and expect to be given
a configuration file as their main argument. See the output of
the -h/--help option from each of them.
Note that timestamps of files in test/ matter. Since git doesn't
support file timestamps, there is a primitive shell script to save
and restore them to a file:
./dostamps set test test.timestamps
# restore test/* timestamps from test.timestamps data
./dostamps get test test.timestamps
# save test/* timestamps to test.timestamps
You need to do the former before starting to do stuff with DWiki.
You want to do the latter before commiting any new or changed files
in test/*.
In addition to using the commands above, you can also potentially
run DWiki as a WSGI application with a normal (general) WSGI server
such as uWSGI, Apache's mod_wsgi, or gUnicorn. To do so you will
need to create a WSGI 'application' callable thing, which is built
as follows:
import dwconfig
application, _ = dwconfig.materialize("/path/to/dwiki.conf", None)
(The second argument to dwconfig.materialize is somewhat complicated, but
passing None is the simple version.)
More information:
http://utcc.utoronto.ca/~cks/space/dwiki/DWiki
http://utcc.utoronto.ca/~cks/space/dwiki/
Author:
Chris Siebenmann
Copyright:
GPL v3 for now. Someday there will be notes about this in files and so on.