UFW firewall is not working on Ubuntu in DigitalOcean

前端 未结 3 949
难免孤独
难免孤独 2021-02-02 02:42

In my DigitalOcean (DO) droplet I installed this image: Ubuntu Docker 17.12.0~ce on 16.04 (which is available on ** DO website > droplet> destroy> rebuild dropl

3条回答
  •  北恋
    北恋 (楼主)
    2021-02-02 03:09

    Docker and UFW don't work together too well as they both modify iptables but there's a way to fix this. You'll need to configure Docker to not use iptables. Add

    DOCKER_OPTS="--iptables=false"
    

    to /etc/default/docker and restart your host (or restart the Docker daemon and UFW).

    These two links have a lot more information about the issue:

    https://blog.viktorpetersson.com/2014/11/03/the-dangers-of-ufw-docker.html
    https://www.techrepublic.com/article/how-to-fix-the-docker-and-ufw-security-flaw/

提交回复
热议问题