From: Ondřej Surý Date: Thu, 25 May 2017 10:23:59 +0000 (+0200) Subject: Update the moduledir documentation X-Git-Tag: v1.3.0~9^2~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a5c4724d586517c1e69b79b77bdd963124cd67f8;p=thirdparty%2Fknot-resolver.git Update the moduledir documentation --- diff --git a/daemon/README.rst b/daemon/README.rst index 26301b9fc..ba01fb864 100644 --- a/daemon/README.rst +++ b/daemon/README.rst @@ -380,7 +380,15 @@ Environment hostname. If called without a parameter, it will return kresd's internal hostname, or the system's POSIX hostname (see gethostname(2)) if kresd's internal hostname is unset. - + +.. function:: moduledir([dir]) + + :return: Modules directory. + + If called with a parameter, it will change kresd's directory for + looking up the dynamic modules. If called without a parameter, it + will return kresd's modules directory. + .. function:: verbose(true | false) :return: Toggle verbose logging. diff --git a/doc/build.rst b/doc/build.rst index 2b054b5dd..b27ddd7c9 100644 --- a/doc/build.rst +++ b/doc/build.rst @@ -175,11 +175,11 @@ All paths are prefixed with ``PREFIX`` variable by default if not specified othe "library", "``LIBDIR``", "``$(PREFIX)/lib``", "pkg-config is auto-generated [#]_" "daemon", "``SBINDIR``", "``$(PREFIX)/sbin``", "" "configuration", "``ETCDIR``", "``$(PREFIX)/etc/kresd``", "Configuration file, templates." - "modules", "``MODULEDIR``", "``$(LIBDIR)/kdns_modules``", "[#]_" + "modules", "``MODULEDIR``", "``$(LIBDIR)/kdns_modules``", "Runtime directory for loading dynamic modules [#]_." "work directory", "", "``$(PREFIX)/var/run/kresd``", "Run directory for daemon." .. [#] The ``libkres.pc`` is installed in ``$(LIBDIR)/pkgconfig``. -.. [#] Users may install additional modules in ``~/.local/lib/kdns_modules`` or in the rundir of a specific instance. +.. [#] The default moduledir can be changed with `-m` option to `kresd` daemon or by calling `moduledir()` function from lua. .. note:: Each module is self-contained and may install additional bundled files within ``$(MODULEDIR)/$(modulename)``. These files should be read-only, non-executable.