ttimasdf / docker-cve-search

Dockerized cve-search as a web app
MIT License
16 stars 15 forks source link

Redis data is never saved #2

Closed electricworry closed 10 months ago

electricworry commented 6 years ago

The redis server is run directly as opposed to though the init scripts and therefore doesn't use the configuration in /etc/redis/redis.conf. This means that the SAVE configuration is empty and redis will never write to disk.

Since you are only running the redis cache updater on image creation (not on container startup) the redis cache (and the vendor list) is always empty at runtime.

I suggest changing:

redis-server --loglevel notice &

to:

/etc/init.d/redis-server start

This will make redis dump the data when a batch of records are updated.