installed Docker on Debian 11 but the created container does not have internet access. For example, an nginx container cannot bind to port 80 and logs show permission denied.
I checked AppArmor logs in dmesg and I saw this.
[ 1334.886165] audit: type=1400 audit(1695623693.319:93): apparmor="DENIED" operation="create" namespace="root//lxd-bullseye_<var-snap-lxd-common-lxd>" profile="docker-default" pid=5079 comm="nginx" family="unix" sock_type="stream" protocol=0 requested_mask="create" denied_mask="create" addr=none
[ 1334.886170] audit: type=1400 audit(1695623693.319:94): apparmor="DENIED" operation="create" namespace="root//lxd-bullseye_<var-snap-lxd-common-lxd>" profile="docker-default" pid=5079 comm="nginx" family="unix" sock_type="stream" protocol=0 requested_mask="create" denied_mask="create" addr=none
[ 1334.886193] audit: type=1400 audit(1695623693.319:95): apparmor="DENIED" operation="create" namespace="root//lxd-bullseye_<var-snap-lxd-common-lxd>" profile="docker-default" pid=5079 comm="nginx" family="unix" sock_type="stream" protocol=0 requested_mask="create" denied_mask="create" addr=none
[ 1334.886196] audit: type=1400 audit(1695623693.319:96): apparmor="DENIED" operation="create" namespace="root//lxd-bullseye_<var-snap-lxd-common-lxd>" profile="docker-default" pid=5079 comm="nginx" family="unix" sock_type="stream" protocol=0 requested_mask="create" denied_mask="create" addr=none
[ 1334.887506] audit: type=1400 audit(1695623693.319:97): apparmor="DENIED" operation="create" namespace="root//lxd-bullseye_<var-snap-lxd-common-lxd>" profile="docker-default" pid=5079 comm="nginx" family="inet" sock_type="stream" protocol=0 requested_mask="create" denied_mask="create"
Why is that apparmor is denying network access? I just installed Docker by following the docker documentation.