Search | Sailfish OS | Running | PineTime | All Posts

Adopting a very simple Wiki

December 04, 2023 — Nico Cartron

The Need

I wanted to document some of my home network setup, and have it available when outside without VPN.

I also wanted this to be light and easy to use, and with Markdown support.

The choice

I did a quick search on GitHub, but there were too many results, and most were not matching my requirements: from the ones requiring a database, to the ones in Java.

Then I did a quick search in DuckDuckGo, and stumbled upon w2wiki, whose repo is on... GitHub :-)

w2wiki description was clear: "A web-based, wiki-like notepad that you host yourself."
Clearly ticked a lot of boxes, so I decided to give it a go.

Installation

Getting the code

I am hosting it on a FreeBSD server, so a

git clone https://github.com/panicsteve/w2wiki.git

was all I had to do.

Web server configuration

I created a virtual host, Let's Encrypt certificate and new DNS record for w2wiki, secured the access with a .htaccess, and I was good to go.

The nice thing is that you can edit pages directly in the browser, using Markdown:

It works the same way as any wiki, i.e. to create a new page, you would type:

[[MyPage]]

in a new page, which would link to it, and would allow you to edit it then.

Local sync

Since the pages are stored as flat files, I setup a shell script which rsyncs the content of a local folder, where I create my articles using vim.
I can also sync any page created through the web version.

Wrap Up

Happy with that setup, which allows me maintaining this wiki from the command line, and also adding / modifying stuff if needs be from a web browser.


Tags: IT


I don't have any commenting system, but email me (nicolas at ncartron dot org) your comments!
If you like my work, you can buy me a coffee!