From 13f1752636f4acc91b2819a8867359bb297e1c42 Mon Sep 17 00:00:00 2001 From: Timur Ismagilov Date: Sat, 31 Jul 2021 19:49:18 +0500 Subject: [PATCH] Document lock --- help/en/lock.myco | 27 ++++ views/stuff.qtpl | 1 + views/stuff.qtpl.go | 305 ++++++++++++++++++++++---------------------- 3 files changed, 181 insertions(+), 152 deletions(-) create mode 100644 help/en/lock.myco diff --git a/help/en/lock.myco b/help/en/lock.myco new file mode 100644 index 0000000..f9fe718 --- /dev/null +++ b/help/en/lock.myco @@ -0,0 +1,27 @@ +# Lock +//This article is intended for wiki administrators.// + +Sometimes, you may want to let only authorized users to view your wiki. This is when **lock** comes in handy. + +## Enabling +In `config.ini`, set `Locked` to `true` to enable. `UseAuth` must also be `true`. +```ini +... +[Authorization] +UseAuth = true +Locked = true +... +``` + +Restart your wiki. + +## Usage +When unauthorized people visit your wiki, they will see something like this: +img { +https://mycorrhiza.wiki/binary/release/1.3/lock_screenshot +} + +If they log in, they will be able to navigate the wiki. They are not able to register, though. [[/help/en/telegram | Telegram]] authorization is supported. + +## See also +=> /help/en/whitelist Whitelist \ No newline at end of file diff --git a/views/stuff.qtpl b/views/stuff.qtpl index 2d12609..c994f97 100644 --- a/views/stuff.qtpl +++ b/views/stuff.qtpl @@ -157,6 +157,7 @@ It outputs a poorly formatted JSON, but it works and is valid.
  • Configuration (for administrators)