We have deployed LibreNMS on a swarm cluster using the official librenms image.
There are about 6 pollers instances working indepently of cron, web ui, rrdcached, memcached, etc.
We use traefik as ingress proxy and would like to fire another instance of web UI to distribute load.
The problem is Laravel’s session handling. We have shared the /opt/librenms/framework/sessions over NFS to get access to session from all instances across the cluster. When we do that, the web ui starts becoming slow responding. On the other hand, running just one instance with session filesystem as a local docker volume everything goes right.
Is there a way to do that? I’ve seen that Laravel supports memcached as session driver, but need a PECL extension to do that.
The redis connection is predefined, so you could just set .env variables for it.
To use memcached, you would have to edit the config/database.php file to add a new connection for memcached as it isn’t there right now. However, you could easily add that upstream so you can just use env variables for that too.
How can I check if I passed variables correctly to laravel configuration?
I’m doing it with compose file inside “environment” setting, but can’t see if it is ok inside laravel.
If you set them in the container they should be passed through. I would manually go in and get the settings right in the .env file, then once you verify the settings are correct, you can set them on the container as they should be.