Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZeger-Jan van de Weg <git@zjvandeweg.nl>2017-08-17 20:24:14 +0300
committerZeger-Jan van de Weg <git@zjvandeweg.nl>2017-09-08 16:42:59 +0300
commitcdb4ab073c7c4c3a9ef53df4c6f13e6642878395 (patch)
tree290824074f2135278eb610b92a4c16aa30f4b624 /README.md
parent740ae0ce780b71c5d669a265f63ddd9095214704 (diff)
Use namsral/flag to support environment vars for config
Diffstat (limited to 'README.md')
-rw-r--r--README.md32
1 files changed, 32 insertions, 0 deletions
diff --git a/README.md b/README.md
index 35054303..d23baaf5 100644
--- a/README.md
+++ b/README.md
@@ -104,6 +104,38 @@ to work. However, if it's running on a private network, this may allow websites
on the public Internet to access its contents *via* your user's browsers -
assuming they know the URL beforehand.
+### Configuration
+
+The daemon can be configured with any combination of these methods:
+1. Command-line options
+1. Environment variables
+1. Configuration file
+1. Compile-time defaults
+
+To see the available options and defaults, run:
+
+```
+./gitlab-pages -help
+```
+
+When using more than one method (e.g., configuration file and command-line
+options), they follow the order of precedence given above.
+
+To convert a flag name into an environment variable name:
+- Drop the leading -
+- Convert all - characters into _
+- Uppercase the flag
+
+e.g., `-pages-domain=example.com` becomes `PAGES_DOMAIN=example.com`
+
+A configuration file is specified with the `-config` flag (or `CONFIG`
+environment variable). Directives are specified in `key=value` format, like:
+
+```
+pages-domain=example.com
+use-http2=false
+```
+
### License
MIT