In case this may get you moving forward here’s how I was able to pass some custom commands to IPFS docker:
Note the dockerfile-ipfs on line 59. That file is in the same folder.
My other tip is you can just potentially shell into your docker IPFS containner, and run the command line option to set the configuration parameter, and then restart the daemon. Updating config param always requires a restart.
Also there maybe there’s a way to specify a specific config file location on the deamon startup command. I can’t remember if there is. Hope it helps. It’s not a direct answer, but I’m just making sure you know of this way to configure parameters.
Thanks a lot for the tips. I tried multiple ways (using ways suggested by you as well) to set net.core.rmem_max inside the container but have not succeeded yet
Some errors I encountered when trying to configure it (putting these here so that anyone encounter the same errors can search for the solution if anyone come up with any idea):
(when trying to set sysctls in docker-compose.yml)
OCI runtime create failed: container_linux.go:349: starting container process caused "process_linux.go:449: container init caused \"write sysctl key net.core.rmem_default: open /proc/sys/net/core/rmem_default: no such file or directory\"": unknown
(when trying to configure from the container's shell)
sysctl: error: 'net.core.rmem_max' is an unknown key
And I read the forum post you attached too. However, such solution seems to change the config on the host machine while I prefer a solution to set it within the container while leaving the host machine untouched.