TazWikiss
5.1
TazWikiss is a tiny wiki written in shell, a port of WiKiss. It runs as CGI scripts, so it needs a web server but no PHP and no database: each page is a plain text file. It is good for notes on one machine or a small home network.
Install
# spk-add tazwikiss
The wiki goes to /var/www/wiki/, owned by the www user so the web
server can write the pages. The installation sets up the web server for
you:
- with Lighttpd installed, it adds a block that runs the
.shfiles of/wiki/as CGI to/etc/lighttpd/lighttpd.conf, and restarts Lighttpd; - with no Lighttpd (or Apache), it sets up the busybox
httpd: the line*.sh:/bin/shin/etc/httpd.conf, andhttpdinRUN_DAEMONSof/etc/rcS.conf.
Installing Lighttpd is explained in the
Handbook. If you
install it after TazWikiss, install TazWikiss again
(spk-add --forced tazwikiss) so it sets up Lighttpd too.
Open the wiki
From the menu: Wiki documents. Or from a terminal:
$ browser http://localhost/wiki/index.sh
From another machine, put the name or IP address of the server in
place of localhost.
The wiki opens on its Welcome page (Accueil in French). Every page has
an Edit link. To make a new page, write its name between brackets in a
page, [MyPage], save, and follow the link. The Help page lists the syntax; HelpTables and
HelpCalc show tables and the spreadsheet plugin.
Where things are
/var/www/wiki/pages/: the pages, one.txtfile each, no sub-directories;/var/www/wiki/historique/: the older versions of each page, behind the History link;/var/www/wiki/config.sh: the settings: title, start page, password, words of the interface;config-fr.shandconfig-de.sh: the same in French and German. The wiki picks the file from the language of the browser;/var/www/wiki/plugins/: tables, calc, page passwords, upload, RSS, full screen and administration.
To back up the wiki, copy pages/ and historique/.
Protect the wiki
Out of the box anyone who reaches the web server can edit every page. The message at the end of the installation says the default password is "test": that is wrong, there is none. If other machines can reach your web server, set a password at once.
As root, in /var/www/wiki/config.sh, replace the first line:
PASSWORD="your-password"
Do the same in config-fr.sh and config-de.sh, or a browser in
French or German edits without one. Editors then type the password
below the text when they save.
Hide a page
To ask for a password before showing a page, write this anywhere in it:
{PASSWORD=read-password}
When the page is saved, the password is replaced by a hash in the file, and readers get a password field instead of the text.
Troubleshooting
The browser downloads index.sh or shows its code: the web server
does not run it as CGI. With Lighttpd, look for the "/wiki/" block in
/etc/lighttpd/lighttpd.conf, with ".sh" => "/bin/sh"; with busybox
httpd, for *.sh:/bin/sh in /etc/httpd.conf. Then restart the
server: trame service restart lighttpd (or httpd).
Saving does nothing: the web server cannot write in
/var/www/wiki/pages/. Give the files back to it:
# chown -R www:www /var/www/wiki
Nothing answers on localhost: no web server is running.
trame service list shows it.
Links
- Servers in the Handbook
- WiKiss, the PHP wiki it comes from