]> git.immae.eu Git - github/shaarli/Shaarli.git/blobdiff - doc/Server-configuration.html
Bump version to v0.8.1
[github/shaarli/Shaarli.git] / doc / Server-configuration.html
index 068900b88ee35484b05adf831c30e55881f07712..2f1c25b50f0ff78c6953cea7d87f0f5d4b790238 100644 (file)
@@ -193,6 +193,9 @@ code > span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Inf
     ErrorLog<span class="st">  /var/log/apache2/shaarli-error.log</span>
     CustomLog<span class="st"> /var/log/apache2/shaarli-access.log combined</span>
 <span class="fu">&lt;/VirtualHost&gt;</span></code></pre></div>
+<h3 id="htaccess">.htaccess</h3>
+<p>Shaarli use <code>.htaccess</code> Apache files to deny access to files that shouldn't be directly accessed (datastore, config, etc.). You need the directive <code>AllowOverride All</code> in your virtual host configuration for them to work.</p>
+<p><strong>Warning</strong>: If you use Apache 2.2 or lower, you need <a href="https://httpd.apache.org/docs/current/mod/mod_version.html">mod_version</a> to be installed and enabled.<a href=".html"></a></p>
 <h2 id="lighthttpd">LightHttpd</h2>
 <h2 id="nginx">Nginx</h2>
 <h3 id="foreword">Foreword</h3>
@@ -233,7 +236,7 @@ code > span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Inf
 <li>files may be located in a user's home directory</li>
 <li>in this case, make sure both Nginx and PHP-FPM are running as the local user/group!</li>
 </ul>
-<p>For all following examples, a development configuration will be used:</p>
+<p>For all following configuration examples, this user/group pair will be used:</p>
 <ul>
 <li><code>user:group = john:users</code>,</li>
 </ul>
@@ -251,6 +254,24 @@ user john users;
 http {
     [...][](.html)
 }</code></pre>
+<h3 id="optional-increase-the-maximum-file-upload-size">(Optional) Increase the maximum file upload size</h3>
+<p>Some bookmark dumps generated by web browsers can be <em>huge</em> due to the presence of Base64-encoded images and favicons, as well as extra verbosity when nesting links in (sub-)folders.</p>
+<p>To increase upload size, you will need to modify both nginx and PHP configuration:</p>
+<pre class="nginx"><code># /etc/nginx/nginx.conf
+
+http {
+    [...][](.html)
+
+    client_max_body_size 10m;
+
+    [...][](.html)
+}</code></pre>
+<div class="sourceCode"><pre class="sourceCode ini"><code class="sourceCode ini"><span class="co"># /etc/php5/fpm/php.ini</span>
+
+<span class="kw">[...][]</span><span class="dt">(.html)</span>
+<span class="dt">post_max_size </span><span class="ot">=</span><span class="st"> 10M</span>
+<span class="kw">[...][]</span><span class="dt">(.html)</span>
+<span class="dt">upload_max_filesize </span><span class="ot">=</span><span class="st"> 10M</span></code></pre></div>
 <h3 id="minimal-1">Minimal</h3>
 <p><em>WARNING: Use for development only!</em></p>
 <pre class="nginx"><code>user john users;
@@ -350,6 +371,11 @@ http {
             error_log   /var/log/nginx/shaarli.error.log;
         }
 
+        location = /shaarli/favicon.ico {
+            # serve the Shaarli favicon from its custom location
+            alias /var/www/shaarli/images/favicon.ico;
+        }
+
         include deny.conf;
         include static_assets.conf;
         include php.conf;
@@ -403,6 +429,11 @@ http {
             error_log   /var/log/nginx/shaarli.error.log;
         }
 
+        location = /shaarli/favicon.ico {
+            # serve the Shaarli favicon from its custom location
+            alias /var/www/shaarli/images/favicon.ico;
+        }
+
         include deny.conf;
         include static_assets.conf;
         include php.conf;