Merge branch 'mode_local_slave_distant' into dist/eole/2.6.2/master

This commit is contained in:
Teddy Cornaut 2018-09-04 15:58:05 +02:00
commit 9bdc26ad51
2 changed files with 22 additions and 1 deletions

View File

@ -49,9 +49,15 @@
<!-- Instance Secondaire -->
<variable name='redisSlaveInstanceName' type='string' description="Nom de l'instance secondaire"/>
<variable name='redisSlaveInstanceMaster' type='string' description="Nom du noeud a répliquer sur l'instance secondaire"/>
<variable name='redisPortSlave' type='number' description="Port d'écoute du service Redis">
<variable name='redisMasterIPSlave' type='ip' description="IP du service Redis master">
<value>127.0.0.1</value>
</variable>
<variable name='redisMasterPortSlave' type='number' description="Port d'écoute du service Redis master">
<value>6379</value>
</variable>
<variable name='redisPortSlave' type='number' description="Port d'écoute du service Redis slave">
<value>8379</value>
</variable>
<variable name='redisClPortSlave' type='number' description="Port d'écoute du service Cluster Redis"/>
<variable name='redisMaxMemorySlave' type='number' description="Quantité de mémoire utilisable par Redis en Mo">
<value>512</value>
@ -152,6 +158,15 @@
<condition name='disabled_if_in' source='redisMode'>
<param>Local avec slave distant</param>
<target type='variable'>redisRole</target>
<target type='variable'>redisSlaveInstanceName</target>
<target type='variable'>redisSlaveInstanceMaster</target>
<target type='variable'>redisClPortSlave</target>
</condition>
<condition name='disabled_if_not_in' source='redisMode'>
<param>Local avec slave distant</param>
<target type='variable'>redisMasterIPSlave</target>
<target type='variable'>redisMasterPortSlave</target>
</condition>
<condition name='disabled_if_in' source='redisRole'>

View File

@ -83,6 +83,12 @@ protected-mode no
# If port 0 is specified Redis will not listen on a TCP socket.
port %%redisPortSlave
%if %%redisMode == 'Local avec slave distant'
slaveof %%redisMasterIPSlave redisMasterPortSlave
%endif
# TCP listen() backlog.
#
# In high requests-per-second environments you need an high backlog in order