Making the firewall and Fail2ban work properly is not straightforward.
First I had to remove UFW
# remove UFW
sudo ufw disable
sudo service ufw stop
sudo apt-get purge ufw
sudo apt-get autoremove
sudo apt-get autoclean
For more information how to set up the firewall to make Freedom Box work within a VPN and possibly communicate with the matrix server have a look to : FreedomBox on LXC - #7 by Ramon