kobotoolbox / kobo-docker

Stack of docker containers to all server-side components of KoBoToolbox (kpi, kobocat, enketo-express).
179 stars 203 forks source link

Add maxmemory setting in redis cache template #318

Closed noliveleger closed 2 years ago

noliveleger commented 2 years ago

maxmemory setting can be customized with REDIS_CACHE_MAX_MEMORY environment variable. It caps the memory in redis configuration but also as a docker level (the container memory is capped).

Related to https://github.com/kobotoolbox/kobo-install/pull/170

noliveleger commented 2 years ago

For the record, I wanted to upgrade to compose file version 3 for back-end compose files, but mem_limit and extend have been deprecated. extend could have been replaced with duplicating some lines in primary and secondary overrides files but the mem_limit has been replaced with a sub option of deploy option. deploy option can be used only with docker stack command which requires docker engine v1.25 and more. Unfortunetaly, our servers still use v1.24. Moreover, kobo-install would need many changes to support this command.