Occ leads to "Fatal error: Allowed memory size of ... bytes exhausted"

I am using Nextcloud on docker.
Once in a while and yesterday again, Nextcloud went into maintenance mode…
I tried to put it back to operation by

  • going to my container by “docker exec -it nextcloud-app /bin/bash”
  • put maintenance mode off by “sudo -u www-data php occ maintenance:mode --off”

but I receive a fatal error
Fatal error: Allowed memory size of 2097152 bytes exhausted (tried to allocate 446464 bytes) in /var/www/html/3rdparty/composer/autoload_real.php on line 37

looks like even any occ call is failing the same way.

Is there a route cause (I didnt change things)? How can I increase the memory to avoid that error?

Hi. Have the same here. I was upgrading from 20.0.9 to 20.0.11 but my nextcloud stays in maintenance mode:

Fatal error: Allowed memory size of 2097152 bytes exhausted (tried to allocate 405504 bytes) in /var/www/html/3rdparty/composer/autoload_real.php on line 35

Do you have any news so fare?