I’m using docker-compose to make the interaction of my c++ binary with mongodb. Since the binary is mounted at the container through a volume, everytime I recompile my app, the new binary is gonna be inside the container. I need to make the container restart the program so it loads the new binary. Obviously I could just restart everything by doing control + C and then docker-compose up agaib, but this process slows down everything, as I need to wait for al the other containers to start again.
I trried to do docker attach on the container that runs the binary but it hangs forever. What should I do?
If there is a way to restart only the container that has the binary, that’s great, but it’d be even beter if I could just get inside the container and stop/re-run the binary over and over