Hello, i'm using the latest image (with nextcloud 14)
and when i run any php occ command. i get this message
The current PHP memory limit is below the recommended value of 512MB.
i haven't touch the image. it's the official image from docker hub vanilla (with clean installation to mariadb)
It's a good idea to PR this ?
RUN echo 'memory_limit = 512M' >> /usr/local/etc/php/conf.d/docker-php-memlimit.ini;
in Dockerfile of NC14 ?
This is already set in .htaccess and .user.ini. Have you modified them?
You can also mount a custom config into /usr/local/etc/php.
Hello,
i have the same problem ,
the php limit is to 128 (php -i | grep memory_limit)
the values in .htacess and user.ini are set to 512
@J0WI No, as i said. i've just run
docker run nextcloud
and then in this new nextcloud run "php occ" then i get the message of warning 128MB
@bitdegree67
You can change it with
echo 'memory_limit = 512M' >> /usr/local/etc/php/conf.d/docker-php-memlimit.ini;
inside the docker container
but i think its temporary and hacky
@xXZaretXx I myself proposed this solution
@bitdegree67 ups yes you are right , i'm blind
Hello,
i have the same problem ,someone who can slove it. thanks.
Thanks for providing the details. I can now reproduce the issue.
@tilosp since this has been added in https://github.com/nextcloud/server/pull/10539 (NC 14), should we change the defaults for the container?
The question is why .htaccess isn't used by "php occ"
Because it's the cli and not apache
Alright! so it's dsn't a problem for nextcloud, only for occ
@bitdegree67 It is apparently still an issue with the php-fpm variant. My current solution is to have my own derived Dockerfile which simply increases the mem limit, but I think this should really be included in upstream (php-fpm and the alpine alt).
Edit: I've just realized that the memory-limit configuration is also present in .user.ini, but somehow nextcloud was still complaining.
There are two different checks in NextCloud:
.htaccess or .user.iniocc cli util (since NextCloud 14), which uses PHP defaultsYou can always mount a custom my-config.ini file, that contains e.g. memory_limit = 512M, into /usr/local/etc/php/conf.d/.
I've created #460 to ship this setting by default.
pora
Thank you
Most helpful comment
@bitdegree67
You can change it with
echo 'memory_limit = 512M' >> /usr/local/etc/php/conf.d/docker-php-memlimit.ini;inside the docker container
but i think its temporary and hacky