Docker containers can't telnet external host in 993 port (IMAP SSL)

Hi there.

I have a Docker host where I can telnet an external host normally, in port 993 (IMAP SSL).
However, in any container I can’t do it.

I guess it has something to do with iptables not allowing some ports out, don’t really know why, as other ports I can telnet, such as smtp port on other host, also external.

Is there any easy way to do this change (allow communication out on this host/port), but don’t affect any other containers?

Thanks a lot.
Best regards,
Luis Nabais

Did you ever get an answer to this question? I am currently experiencing the same issue where I can telnet from the host machine (to a RabbitMQ port, 5671), but not from within the container.

Thanks.