Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
software:dokuwiki [2011/01/20 15:25]
cyril [Have it working on free.fr] traduction, ajout interdiction
software:dokuwiki [2013/09/19 20:04]
cyril add nginx support
Line 10: Line 10:
 Cependant dokuwiki est dorénavant banni chez Free. Si vous êtes détecté, votre compte sera suspendu pour le motif : Cependant dokuwiki est dorénavant banni chez Free. Si vous êtes détecté, votre compte sera suspendu pour le motif :
 >Les interfaces utilisant des fichiers locaux comme base de données/log sont interdites. >Les interfaces utilisant des fichiers locaux comme base de données/log sont interdites.
 +
 +===== Install with Nginx =====
 +
 +userewrite = 2 (dokuwiki is rewriting) did not work with nginx, so I wanted to switch to mode 1 where the web server manages rewriting.
 +
 +There are suggestions of configuration [[https://www.dokuwiki.org/rewrite#nginx|here]] and [[http://wiki.nginx.org/Dokuwiki|here]] but they all seemed to assume that the wiki was at the root of the server, and the "@dokuwiki" syntax did not work in my case, when I want to access the wiki with domain.tld/wiki.
 +
 +Therefore I use this configuration, that in addition permanently redirects the old rewrite mode 2 to mode 1:<code>
 +                # always needed
 +                location ~ /wiki/(data|conf|bin|inc) {
 +                        deny all;
 +                }
 +                
 +                # needed to support old rewrite
 +                location ~ /wiki/doku.php/ {
 +                        rewrite ^/wiki/doku.php/(.*) /wiki/$1 permanent;
 +                }
 +
 +                # needed for new rewrite
 +                location ~ /wiki/lib/ {}
 +                location ~ /wiki/ {
 +                        rewrite ^/_media/(.*) /lib/exe/fetch.php?media=$1 last;
 +                        rewrite ^/_detail/(.*) /lib/exe/detail.php?media=$1 last;
 +                        rewrite ^/_export/([^/]+)/(.*) /doku.php?do=export_$1&id=$2 last;
 +                        rewrite ^/wiki/(.*) /wiki/doku.php?id=$1 last;
 +                }
 +</code>
  
 ===== The sidebar ===== ===== The sidebar =====
software/dokuwiki.txt · Last modified: 2022/04/08 07:34 by cyril
CC Attribution-Share Alike 4.0 International
Driven by DokuWiki Recent changes RSS feed Valid CSS Valid XHTML 1.0