Can't access web interface when running in KVM with bridge networking

I moved my HA install from a pi to using the HA OS running in KVM. The install is set to use bridge networking. The HA install has an IP that is handed out by my router.

I am able to curl the IP from the host machine and receive the page, but I can’t access it from any other computer on my network. The iptables of the host are configured as below. Any ideas on what I am missing?

-P INPUT ACCEPT
-P FORWARD ACCEPT
-P OUTPUT ACCEPT
-A FORWARD -o br0 -j ACCEPT
-A FORWARD -i br0 -j ACCEPT

Edit: additionally, if I stop the iptables service then I still can’t get to it. Is there a way to make sure I have the bridge setup right? I was assuming that because it is getting the IP that everything is fine, but maybe not. I created the bridge using netplan

  GNU nano 6.2                             /etc/netplan/00-installer-config.yaml *                                    
# This is the network config written by 'subiquity'
network:
  ethernets:
    enp0s31f6:
      dhcp4: no
  bridges:
    br0:
      dhcp4: true
      interfaces:
        - enp0s31f6
      parameters:
        stp: true
  version: 2

If your HA is getting an IP address via DHCP outside the host, then the kernel bridge is working.
Also, make sure the VM interface is not set to NAT.
Here is a pretty good guide to setting this up, and steps 2 and 2.1 in particular may be helpful

I found that thread after posting, and as far as I can tell I have done everything it calls for.

As far as I can tell, it should be using the bridge. You can see the Host IP in the titlebar, the VM IP and the bridge are there too.

image

It looks good to me…
Can you ping HA from any other computer?

Yes. I just can’t access the web interface. Additionally, I know HA is able to reach out and connect to the devices on my network.

also, a curl from the host returns the login page for HA. So I know it is up and running, and I know I can technically access it. It behaves like something is just blocking the traffic on 8123 outside the host :confused:

I disabled netfilter as described on this post, and that didn’t work Install Home Assistant OS with KVM on Ubuntu headless (CLI only) - #14 by oldrobot

Edit! I got it. I also had to delete the NAT network kvm had created. See the final step of that link.