If I understand correctly, you have a program in go that run on Windows and Linux and you encounter some issues when you try to test your program (When you run a MongoDB container). I think the issue could accrue because of the difference in Linux and window or WSL for this purpose, the way WSL work is it translate the commends the Karnal get to Windows and throw them back at you, I recommend doing serial things: