Nextcloud AIO Docker change php memory limit values

Hi there,

I’m trying to increase the php memory limit inside my Nextcloud AIO docker install and have had no idea where the php.ini file is stored. If someone could let me know where it’s stored that would be great as there’s no documentation stating the location that I’ve found

Hi @tekkifygamer

For the official Docker Nextcloud build, you can pass the limits to the container via environment variables ()

Maybe this also works with the AIO Nextcloud.

Assuming you are using docker-compose to start your containers, it could look something like this:

app:
    image: nextcloud
    restart: always
    ports:
      - 8080:80
    links:
      - db
    volumes:
      - nextcloud:/var/www/html
    environment:
      - PHP_MEMORY_LIMIT=1024M
      - PHP_UPLOAD_LIMIT=1024M
     ....

1024M is just an example as both are 512M by default. You, however, need to adjust them to fit your needs and the available memory on your server.