Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blocking internet access for some of the containers #248

Open
hopkinskong opened this issue Dec 20, 2020 · 1 comment
Open

Blocking internet access for some of the containers #248

hopkinskong opened this issue Dec 20, 2020 · 1 comment
Labels
question Further information is requested

Comments

@hopkinskong
Copy link

hopkinskong commented Dec 20, 2020

I would like to block some of the containers (not all of them) to access to the internet, but allowing them accept incoming connections.
This is useful when creating secure rootless containers with applications (servers) that are designed to have internet connections disallowed (e.g. Servers accepting untrusted users' input/running untrusted codes, etc). Is that possible? Or I have to go with iptables (I don't know how to reliably get my containers' IP, and they seem to change when rebuilding the containers though)?

@AkihiroSuda AkihiroSuda added the question Further information is requested label Dec 21, 2020
@AkihiroSuda
Copy link
Member

Should be possible by running iptables inside the container's network namespace, but none of Docker and Podman provides interface for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants