Author: Derick Rethans (derickr)
Date: 2025-04-03T15:26:56+01:00

Commit: 
https://github.com/php/web-wiki/commit/ae3e9504f8898b9919ebe4c9dcf166edf4ecd86b
Raw diff: 
https://github.com/php/web-wiki/commit/ae3e9504f8898b9919ebe4c9dcf166edf4ecd86b.diff

Allow for auth file to be relocated to a different directory

Changed paths:
  A  dokuwiki/inc/preload.php


Diff:

diff --git a/dokuwiki/inc/preload.php b/dokuwiki/inc/preload.php
new file mode 100644
index 00000000..78021f8f
--- /dev/null
+++ b/dokuwiki/inc/preload.php
@@ -0,0 +1,19 @@
+<?php
+/**
+ * This is an example for a farm setup. Simply copy this file to preload.php 
and
+ * uncomment what you need. See http://www.dokuwiki.org/farms for more 
information.
+ * You can also use preload.php for other things than farming, e.g. for moving
+ * local configuration files out of the main ./conf directory.
+ */
+
+// set this to your farm directory
+//if(!defined('DOKU_FARMDIR')) define('DOKU_FARMDIR', '/var/www/farm');
+
+// include this after DOKU_FARMDIR if you want to use farms
+//include(fullpath(dirname(__FILE__)).'/farm.php');
+
+if (getenv("WIKI_AUTH_FILE") !== false) {
+       $config_cascade['plainauth.users'] = array(
+               'default' => getenv('WIKI_AUTH_FILE'),
+       );
+}

Reply via email to