Simple file-based wiki with fulltext-search.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

78 lines
2.6 KiB

7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
  1. # Python Flask Wiki
  2. This is a simple wiki based on Pythons Flask framework.
  3. There is much great wiki software.
  4. Most of them are using some kind of database.
  5. I however just want to put my markdown files in a directory and get a working wiki.
  6. ## Features/To-Dos
  7. - [x] Plain text support for wiki entries
  8. - [x] Markdown Files (.md)
  9. - [x] Entry page
  10. - [ ] Option to get plain text file
  11. - [ ] Optimize CSS for code
  12. - [x] Start page
  13. - [x] Search page
  14. - [x] Full-text search
  15. - [x] Show first few lines of each match (preview)
  16. - [ ] Better CSS
  17. - [ ] Navigation
  18. - [ ] More advanced namespaces
  19. - [x] Header
  20. - [ ] Random article
  21. - [ ] Search bar in header
  22. - [x] Footer
  23. - [x] Switchable CSS
  24. - [x] CSS dark-theme
  25. - [x] CSS light-theme
  26. - [x] Config file
  27. - [ ] Docker installation
  28. - [ ] Enable variables/environment variables
  29. - [ ] Logo
  30. ## Usage
  31. ### Create entries
  32. Wiki entries are managed by plain markdown files in the `templates/entry/` directory.
  33. The first line of each document is reserved as the title of the document.
  34. ## Deployment
  35. ### PIP/Python
  36. - `git clone https://github.com/tiyn/tiyny-wiki`
  37. - `cd tiyny-wiki/src`
  38. - edit the `config.py` file according to your needs
  39. - `pip3install -r requirements.txt` - install depenencies
  40. - run `python app.py`
  41. - wiki is available on port 5000
  42. ### Docker
  43. Make sure you copy an example `config.py` and edit it before running the container.
  44. The `config.py` can be found in the `src` folder.
  45. #### Volumes
  46. Set the following volumes with the -v tag.
  47. | Volume-Name | Container mount | Description |
  48. |-------------|---------------------------|--------------------------------------------------------------|
  49. | config-file | /wiki/src/config.py | Config file |
  50. | entries | /wiki/src/templates/entry | Directory for wiki entries |
  51. | css | /wiki/src/static/css | (optional) Directory for css files |
  52. | html | /wiki/src/templates | (optional) Directory for templates (entry-volume not needed) |
  53. #### Ports
  54. Set the following ports with the -p tag.
  55. | Container-Port | Recommended outside port | Protocol | Description |
  56. |----------------|--------------------------|----------|-------------|
  57. | 5000 | 80 | TCP | HTTP port |
  58. #### Example run-command
  59. `docker run --name wiki --restart unless-stopped -v ./config.py:/wiki/src/config.py -v entries:/wiki/src/templates/entry -p 80:5000 -d tiynger/tiyny-wiki`