strands-project / mongodb_store

MongoDB tools for storing and analysing runs of ROS systems.
BSD 3-Clause "New" or "Revised" License
49 stars 72 forks source link

handling of host binding #270

Closed marc-hanheide closed 2 years ago

marc-hanheide commented 2 years ago

Here is a patch to a common problem: the mongo process binds to $HOSTNAME which may be set to something else than localhost. Then controller here tries to shut it down by connecting to localhost, where it will not be reached and the mongo server process hangs around. This fixes 2 things:

marc-hanheide commented 2 years ago

This is a problem particularly in docker containers, I have found, which have a HOSTNAME set to the docker network IP (e.g. 172.x.x.x, while localhost is 127.0.0.1. So, there it fails, but also in other systems that follow this scheme.

marc-hanheide commented 2 years ago

could a new release be made for this, as the previous indeed cause some issues for users?

hawesie commented 2 years ago

A new release is on my todo list :)