mirror of
https://github.com/filegator/filegator.git
synced 2025-08-21 07:41:36 +02:00
Website generation with Couscous
This commit is contained in:
@@ -102,8 +102,8 @@
|
||||
|
||||
<section class="col-sm-offset-3 col-lg-offset-2 col-sm-9 col-lg-10">
|
||||
<h2 id="default-auth-service">Default Auth service</h2>
|
||||
<p>By default, users are stored in json file. For some use-cases, this is more than enough. It also makes this app lightweight since no database is required.</p>
|
||||
<p>Default handler accepts only file name parameter. This file should be writable by the server.</p>
|
||||
<p>By default, users are stored in json file. For some use-cases, this is enough. It also makes this app lightweight since no database is required.</p>
|
||||
<p>Default handler accepts only file name parameter. This file should be writable by the web server.</p>
|
||||
<pre><code> 'Filegator\Services\Auth\AuthInterface' => [
|
||||
'handler' => '\Filegator\Services\Auth\Adapters\JsonFile',
|
||||
'config' => [
|
||||
@@ -112,7 +112,7 @@
|
||||
],
|
||||
</code></pre>
|
||||
<h2 id="configuring-auth-service-to-use-database">Configuring Auth service to use database</h2>
|
||||
<p>You can use mysql database to store your users.</p>
|
||||
<p>You can also mysql database to store your users.</p>
|
||||
<p>First, create a table <code>users</code> with this sql:</p>
|
||||
<pre><code>CREATE TABLE `users` (
|
||||
`id` int(10) NOT NULL AUTO_INCREMENT,
|
||||
@@ -130,7 +130,7 @@
|
||||
VALUES
|
||||
('guest', 'Guest', 'guest', '', '/', ''),
|
||||
('admin', 'Admin', 'admin', 'read|write|upload|download|batchdownload|zip', '/', '$2y$10$Nu35w4pteLfc7BDCIkDPkecjw8wsH8Y2GMfIewUbXLT7zzW6WOxwq');</code></pre>
|
||||
<p>At the end, open <code>configuration.php</code> and update Auth handler under section <code>services</code> to something like this:</p>
|
||||
<p>At the end, open <code>configuration.php</code> and update AuthInterface handler to:</p>
|
||||
<pre><code> 'Filegator\Services\Auth\AuthInterface' => [
|
||||
'handler' => '\Filegator\Services\Auth\Adapters\Database',
|
||||
'config' => [
|
||||
@@ -141,7 +141,7 @@ VALUES
|
||||
'database' => 'filegator',
|
||||
],
|
||||
],</code></pre>
|
||||
<p>Don't forget to enter correct mysql username, password, and database.</p>
|
||||
<p>Don't forget to enter correct database details.</p>
|
||||
</section>
|
||||
|
||||
</div>
|
||||
|
Reference in New Issue
Block a user