Uncomplicated Firewall (ufw) is a firewall that is designed to be easy to use. It uses a command line interface consisting of a small number of simple commands, and uses iptables for configuration.
Questions tagged [ufw]
195 questions
6
votes
2 answers
How to use Fail2ban under Kubernetes?
Until now I'm using Docker for a hand-made hosting solution on single-VPCs, with fail2ban installed on host and watching at Docker logs from Nginx containers (Each server can host multiple websites, served through an Nginx proxy)
I wonder how it…

Bazalt
- 61
- 1
- 2
5
votes
2 answers
How can I clear any ufw entries that are not in a list with ansible
https://docs.ansible.com/ansible/latest/modules/ufw_module.html
I have configured Ansible 2 to allow a bunch of ip addresses with ufw with entries like this:
- name: allow from this one computer
ufw:
rule: allow
port: 22
src:…

Alex028502
- 3,486
- 2
- 23
- 50
5
votes
0 answers
Docker swarm ignores iptables=false flag
I'm trying to setup a docker swarm, but I want to use ufw to create my own network rules. I've tried both putting --iptables=false in the docker service file, and also putting { "iptables": false } in /etc/docker/daemon.json.
However, whenever I…

Maarten van Beek
- 133
- 1
- 8
5
votes
2 answers
deploy local nginx server to public ubuntu 16.04
I am trying to deploy my local nginx server to the public. The nginx server runs as a reverse proxy to my node express app which is also running locally on port 3000. Therefore I have created a symbolic link from /etc/nginx/sites-available/express …

sami_analyst
- 1,751
- 5
- 24
- 43
5
votes
1 answer
Ansible ufw module ERROR: Could not find a profile matching 'xxxxx'
I'm working to setup UFW rules via Ansible. I'm able to get it installed, start it and deny everything. I then attempt to allow connections from http, https, and ssh. All attempts to add the allow for those items are met with errors that look…

Greg
- 6,453
- 9
- 45
- 61
4
votes
2 answers
ufw seems not to block all ports (Ubuntu with Docker)
There is a server with Ubuntu 20. It has Docker installed, and several containers are running. The reverseproxy is a Nginx that should take traffic on 80 and 443, and route it to the containers. It works perfectly. But now I wanted to block all…

jkulak
- 768
- 1
- 6
- 18
4
votes
1 answer
ufw forbids docker container to connect to postgres
On ubuntu 18.04 with ufw enabled I run docker container which is supposed to connect a django app to a locally installed Postgresql server.
Everything runs perfect when ufw is disabled
docker-compose -f docker-compose.prod.yml run --rm app sh -c…

arpa
- 328
- 3
- 13
4
votes
1 answer
Docker localhost connection blocked by UFW
Situation
I'm trying to learn how to use docker on my local machine. The local machine is set up to only route traffic through a VPN. The default UFW policy is to DENY all incoming and outgoing traffic (except through a VPN).
Problem
When I try to…

Hermes
- 213
- 1
- 2
- 7
4
votes
1 answer
Docker ufw connect to host machine
I tried out Docker with UFW and i read a lot of this.
My goal was to connect to an mariadb database on the host machine from an docker image.
Host (running ufw) -> docker container 1 - mediawiki -> Database (onHost)
-> docker…

Maulwurf Maulwurfn
- 51
- 1
- 4
4
votes
0 answers
How to configure ufw to work with kubernetes
I set DEFAULT_FORWARD_POLICY to ACCEPT as recommended in docker documentation but seems it's not enough, etcd is not accessible from my containers.

chingis
- 1,514
- 2
- 19
- 38
3
votes
0 answers
UFW not blocking traffic to microk8s cluster
I successfully deployed k8s pod with service of type NodePort in microk8s cluster. Now when I enable UFW and try to deny incoming traffic to the exposed port 31001 using command ufw deny 31001 , UFW still allows traffic to port 31001.
What should I…

ajay vasudevan
- 69
- 8
3
votes
1 answer
Do we need ufw in gcp? or gcp's firewall is good enough?
Do we need ufw in gcp? or gcp's provided Firewall is good enough?

Manav Sengupta
- 101
- 1
- 10
3
votes
1 answer
ansible ufw configuration : default config different from expected
- name: defaultt policy
ufw:
policy: "{{ item.policy }}"
direction: "{{ item.direction }}"
with_items: "{{ ufw_default_dict }}"
become: yes
notify: reload ufw
ufw_default_dict:
- { direction: incoming, policy: deny }
- {…

Ayra
- 328
- 2
- 12
3
votes
2 answers
ubuntu 18.04 server ufw is not blocking even after configuring DOCKER_OPTS="iptables=false"
i have been trying all the solutions i found to block incoming traffic to port 5432 but with no success. there is an issue with docker skipping ufw and it has been advised to configure DOCKER_OPTS="iptables=false" in /etc/default/docker, i have done…

T.G
- 53
- 5
2
votes
4 answers
ROS2 on multiple machines: ros2 multicast working, talker/listener not working
PROBLEM
I have installed ROS 2 foxy on 2 computers and trying to run the demo talker on one machine and the demo listener on the other. Unfortunately it does not work.
However:
the ros2 multicast test works;
the talker/listener DO work when I…

martin_0004
- 357
- 1
- 2
- 15