What is the recommened way of stopping Stardog running in a docker container? Is it sufficient to run
docker stop stardog7; docker rm stardog7
or should we run stardog-admin in the container to stop stardog before stopping the container? It seems like we sometimes loose some configuration data when we just stop and remove the container.
Stardog should handle the SIGTERM sent by docker upon the stop command being issued. By default, Docker will send a SIGKILL after 10 seconds. To avoid a potential hard shutdown, you can use -t to increase the number of seconds that Docker waits after the SIGTERM. The safest solution, is as you mentioned, running stardog-admin shutdown in the container first before stopping the underlying container.
I am curious as to the configuration loss you mentioned and if that is a config change just before shutdown, or any other circumstances that caused a config loss.