Skip to content

Commit 9aed369

Browse files
author
Jacob Christiansen
committed
Added documentation
1 parent 1394233 commit 9aed369

File tree

1 file changed

+56
-0
lines changed

1 file changed

+56
-0
lines changed

docs/redis-store.txt

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
Redis Store module
2+
=================
3+
4+
<!--
5+
This file is written in Markdown syntax.
6+
For more information about how to use the Markdown syntax, read here:
7+
http://daringfireball.net/projects/markdown/syntax
8+
-->
9+
10+
<!-- {{TOC}} -->
11+
12+
Introduction
13+
------------
14+
15+
The Redis module implements the simpleSAMLphp datastore API, so Redis can be
16+
used for backend storage, i.e. session storage.
17+
18+
Setup
19+
-----
20+
21+
First thing to do is to set up your Redis server(s). This is out side the scope
22+
of this documentation.
23+
24+
Next you must install this module either by obtaining the tarball or by
25+
installing it via composer. The latter is recommended
26+
27+
composer.phar require vendor/simplesamlphp-module-redis 1.*
28+
29+
This will automatically install "predis/predis" as a dependency for ther
30+
module. If you downloaded the module yourself, remember to add predis/predis as
31+
a dependency in your composer.json.
32+
33+
See https://github.com/simplesamlphp/composer-module-installer for more
34+
information on how to insatll simpleSAMLphp modules via composer.
35+
36+
You can now enable the module by
37+
38+
touch /var/simplesamlphp/modules/redis/enable
39+
40+
and copy the config file
41+
42+
cp /var/simplesamlphp/modules/redis/config-templates/module_redis.php /var/simplesamlphp/config
43+
44+
Edit the config file so it fits your setup. The following options can be configured:
45+
46+
`host`
47+
: The hostname used for your Redis server
48+
`prefix`
49+
: Prefix of all keys saved in Redis. Default is 'simplasSALMphp'
50+
`lifetime`
51+
: The maximum tiem a key is stored in Redis. Default is 8 hours
52+
53+
You can now use redis a a valid simpleSAMLphp datastore. Use for session
54+
storage by setting the following in config.php
55+
56+
'store.type' => 'redis:Redis'

0 commit comments

Comments
 (0)