Very slow response of NextCloud with Docker within a VM

There are some posts related to a very very very slow response of NC. Here I add another one because I couldnā€™t find a solution for me.

I have this situation:
On a Ubuntu 20.04 host there is a VirtualBox VM with Ubuntu 20.04. Because I want to access the VM from the host I switch the network to ā€˜bridgeā€™. But for the moment this doesnā€™t matter.

Now I do
docker run -d --name my-nc -p 8080:80 -v /home/gerd/docker/nextcloud:/var/www/html nextcloud

This will export /var/www/html in the VM-host file system to make it persistent and gives an easier access.

Because this is the first start of this container the actual image is downloaded from docker-hub.

Now I expect to be able to access NC via localhost:8080. And this works fine.

I answer the question about User name and Password for the Admin and reach the NC-Desktop after some time.

In Settings - Overview I see that Iā€™m using NC Version 20.0.4 and I see some warnings about ā€˜SQLightā€™ and ā€˜httpsā€™.

Everything seems to be OK.

I reboot the VM, restart the container with ā€˜docker start my-ncā€™ and login with ā€˜localhost:8080ā€™. - Everything fine.

Now we come to my problem:

ā€˜ifconfigā€™ tells me the IP of the VM: 192.168.178.34. My expectation is that I can login with this IP instead of localhost.

So I open another tab in the browser and enter ā€˜http://192.168.178.34:8080ā€™. The response is an error message, because this IP is not known as trusted_domains.

So I do
docker exec --user www-data my-nc php occ config:system:set trusted_domains 1 --value=192.168.178.34

and now I do see the login immediately. I enter my Admin data and wait ā€¦ wait ā€¦ waitā€¦
After a very long time I do see the NC-desktop and I can use it, but everything with an extreme slow motionā€¦

At the same time I can still use NC in the parallel ā€˜localhostā€™-tab as expected,

Is there any idea ?

Try disabling collabora. This has been an issue for weeks.

Thanks. I think you are right. And the ā€˜Fixā€™ mentioned there works for me.