Answer the question
In order to leave comments, you need to log in
Docker traffic blocking how to do?
Hello!
Something completely blunted. I have swarm. And I need to allow only a few ports for access from the outside, for example, port 5000 (repository) is definitely not allowed there, and some local services. And everything would be fine, block yourself calmly in the input and enjoy life, but everything turned out to be so fun.
The nat table has a topic like this
Chain DOCKER-INGRESS (2 references)
pkts bytes target prot opt in out source destination
8 384 DNAT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpt:8080 to:172.18.0.2:8080
19766 1303K RETURN all -- * * 0.0.0.0/0 0.0.0.0/0
Answer the question
In order to leave comments, you need to log in
But I sort of figured it out, the fastest way is to write here and ideas immediately come :) ...
Cunning dnats and other things, plus reading the docks again. In general, you need to filter in the
DOCKER-USER chain. Then it's all good :)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question