Правки конфига keydb
- перечитка старых данных при перезапуске - попытка вырубить репликацию
This commit is contained in:
@@ -21,8 +21,10 @@ services:
|
|||||||
container_name: iptv-keydb
|
container_name: iptv-keydb
|
||||||
image: eqalpha/keydb:latest
|
image: eqalpha/keydb:latest
|
||||||
user: ${KEYDB_UID}:${KEYDB_GID}
|
user: ${KEYDB_UID}:${KEYDB_GID}
|
||||||
|
entrypoint: ["sh", "/entrypoint.sh"]
|
||||||
volumes:
|
volumes:
|
||||||
- ./docker/keydb/keydb.conf:/etc/keydb/keydb.conf
|
- ./docker/keydb/keydb.conf:/etc/keydb/keydb.conf
|
||||||
|
- ./docker/keydb/entrypoint.sh:/entrypoint.sh
|
||||||
- ./docker/keydb/data/:/data:rw
|
- ./docker/keydb/data/:/data:rw
|
||||||
- ./log/keydb:/var/log/keydb/:rw
|
- ./log/keydb:/var/log/keydb/:rw
|
||||||
ports:
|
ports:
|
||||||
|
|||||||
4
docker/keydb/entrypoint.sh
Normal file
4
docker/keydb/entrypoint.sh
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
trap 'echo "Received SIGTERM, saving KeyDB data..."; keydb-cli SAVE; echo "Data saved. Exiting."; exit 0' TERM
|
||||||
|
echo "[entrypoint] Starting KeyDB..."
|
||||||
|
exec keydb-server /etc/keydb/keydb.conf "$@"
|
||||||
@@ -493,7 +493,7 @@ dir /data
|
|||||||
# network partition replicas automatically try to reconnect to masters
|
# network partition replicas automatically try to reconnect to masters
|
||||||
# and resynchronize with them.
|
# and resynchronize with them.
|
||||||
#
|
#
|
||||||
# replicaof <masterip> <masterport>
|
replicaof no one
|
||||||
|
|
||||||
# If the master is password protected (using the "requirepass" configuration
|
# If the master is password protected (using the "requirepass" configuration
|
||||||
# directive below) it is possible to tell the replica to authenticate before
|
# directive below) it is possible to tell the replica to authenticate before
|
||||||
@@ -526,7 +526,7 @@ dir /data
|
|||||||
# UNSUBSCRIBE, PSUBSCRIBE, PUNSUBSCRIBE, PUBLISH, PUBSUB, COMMAND, POST,
|
# UNSUBSCRIBE, PSUBSCRIBE, PUNSUBSCRIBE, PUBLISH, PUBSUB, COMMAND, POST,
|
||||||
# HOST and LATENCY.
|
# HOST and LATENCY.
|
||||||
#
|
#
|
||||||
replica-serve-stale-data yes
|
replica-serve-stale-data no
|
||||||
|
|
||||||
# Active Replicas will allow read only data access while loading remote RDBs
|
# Active Replicas will allow read only data access while loading remote RDBs
|
||||||
# provided they are permitted to serve stale data. As an option you may also
|
# provided they are permitted to serve stale data. As an option you may also
|
||||||
@@ -585,7 +585,7 @@ replica-read-only yes
|
|||||||
#
|
#
|
||||||
# With slow disks and fast (large bandwidth) networks, diskless replication
|
# With slow disks and fast (large bandwidth) networks, diskless replication
|
||||||
# works better.
|
# works better.
|
||||||
repl-diskless-sync no
|
#repl-diskless-sync no
|
||||||
|
|
||||||
# When diskless replication is enabled, it is possible to configure the delay
|
# When diskless replication is enabled, it is possible to configure the delay
|
||||||
# the server waits in order to spawn the child that transfers the RDB via socket
|
# the server waits in order to spawn the child that transfers the RDB via socket
|
||||||
@@ -597,7 +597,7 @@ repl-diskless-sync no
|
|||||||
#
|
#
|
||||||
# The delay is specified in seconds, and by default is 5 seconds. To disable
|
# The delay is specified in seconds, and by default is 5 seconds. To disable
|
||||||
# it entirely just set it to 0 seconds and the transfer will start ASAP.
|
# it entirely just set it to 0 seconds and the transfer will start ASAP.
|
||||||
repl-diskless-sync-delay 5
|
#repl-diskless-sync-delay 5
|
||||||
|
|
||||||
# -----------------------------------------------------------------------------
|
# -----------------------------------------------------------------------------
|
||||||
# WARNING: RDB diskless load is experimental. Since in this setup the replica
|
# WARNING: RDB diskless load is experimental. Since in this setup the replica
|
||||||
@@ -1279,7 +1279,7 @@ disable-thp yes
|
|||||||
#
|
#
|
||||||
# Please check http://redis.io/topics/persistence for more information.
|
# Please check http://redis.io/topics/persistence for more information.
|
||||||
|
|
||||||
appendonly no
|
appendonly yes
|
||||||
|
|
||||||
# The name of the append only file (default: "appendonly.aof")
|
# The name of the append only file (default: "appendonly.aof")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user