
* Split out queue and cache config * Update usages of cache config, * Update default * Cleanup * Make queue optional. * config updates. * changelog * update spec config * Update tests * tweak import * Update default config. * fixup test * Update config.sample.yml Co-authored-by: Andrew Ferrazzutti <andrewf@element.io> Signed-off-by: Will Hunt <will@half-shot.uk> * Update encryption.md Signed-off-by: Will Hunt <will@half-shot.uk> * Clear up worker config Signed-off-by: Will Hunt <will@half-shot.uk> * Update src/config/Config.ts Co-authored-by: Andrew Ferrazzutti <andrewf@element.io> Signed-off-by: Will Hunt <will@half-shot.uk> * update helm config * lint * fix meta * tidy tidy * revert logging change * lint rust --------- Signed-off-by: Will Hunt <will@half-shot.uk> Co-authored-by: Andrew Ferrazzutti <andrewf@element.io>
1.2 KiB
Workers
Hookshot supports running in a worker configuration, using Redis as the middleman process to handle traffic between processes.
Running in multi-process mode
You must first have a working Redis instance somewhere which can talk between processes. For example, in Docker you can run:
docker run --name redis-host -p 6379:6379 -d redis
.
The processes should all share the same config, which should contain the correct config to enable Redis:
queue:
redisUri: "redis://redis-host:6379"
cache:
redisUri: "redis://redis-host:6379"
Note that if encryption is enabled, you MUST enable the cache
config but NOT the queue
config. Workers require persistent
storage in Redis, but cannot make use of worker-mode queues.
Once that is done, you can simply start the processes by name using yarn:
yarn start:webhooks
yarn start:matrixsender
yarn start:app
Be aware that you will need to start all worker types when running in worker mode, as the service does not allow a hybrid worker approach.