aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXavier Del Campo Romero <xavi.dcr@tutanota.com>2023-07-25 00:52:08 +0200
committerXavier Del Campo Romero <xavi.dcr@tutanota.com>2023-07-30 23:41:18 +0200
commit7cc5ab1e796aef5c2103f76915d6139b80ea4794 (patch)
tree409d1a3a61d650ffb41f2d7517e37ebf81b37bc1
parent9bcad04de6e04f10f673c2350db6f68bd94b79a1 (diff)
downloadslcl-7cc5ab1e796aef5c2103f76915d6139b80ea4794.tar.gz
README.md: Inform about -t command line option
-rw-r--r--README.md21
1 files changed, 21 insertions, 0 deletions
diff --git a/README.md b/README.md
index 9d8c583..b583d04 100644
--- a/README.md
+++ b/README.md
@@ -173,6 +173,27 @@ command line option. For example:
slcl -p 7822 ~/my-db/
```
+`slcl` requires a temporary directory where files uploaded by users are
+temporarily stored until moved to the user directory. By default, `slcl`
+attempts to retrieve the path to the temporary directory by inspecting the
+`TMPDIR` environment variable, and falls back to `/tmp` (which is common
+among Unix-like operating systems such as GNU/Linux, although not defined
+by POSIX) if undefined.
+
+If a custom temporary directory is required, it can be defined via command
+line option `-t`. For example:
+
+```sh
+slcl -t ~/my-tmp -p 7822 ~/my-db
+```
+
+**Note:** system-level temporary directories such as `/tmp` might reside
+on a filesytem different than the one where the database resides. This
+would force `slcl` to copy the contents from uploaded files from the
+temporary directory to the database, which might be an expensive operation.
+Therefore, in order to avoid expensive copies, define a custom temporary
+directory that resides on the same filesystem.
+
## Why this project?
Previously, I had been recommended Nextcloud as an alternative to proprietary