If the host dnf repos contain $releasever then using --installroot will fail because it tries to use a rpmdb in the installroot, which starts out empty. Passing --releasever=/ will use the releasever from the host.