I recently set up Nextcloud, and so far I’m really enjoying it. With the exception of Gmail and Backblaze, I’m no longer using any online services that aren’t self-hosted on my own hardware; Nextcloud has allowed me to get rid of the last few Google services I was using.

One issue I’m having is that images I have uploaded to Nextcloud do not have thumbnails when the image size is large. My phone takes photos at 200MP, so this constitutes a significant number of my photos.

I’ve been researching the problem, and I think I need to set the following:

‘preview_max_x’ => null ‘preview_max_y’ => null ‘preview_max_filesize_image’ => -1 ‘preview_max_memory’ => -1

I’m running Nextcloud on a Proxmox hypervisor with 32 cores and 128GB of memory, so I’m not concerned about using system resources; I can always allocate more.

The issue I’m having is that I installed Nextcloud as a snap in Ubuntu Server. The last time I tried to use nextcloud.occ to change a configuration option, it set a string as an array, and triggered a bunch of php errors.

As far as I can tell, I need to do something like this:

sudo nextcloud.occ config:[something, maybe system]:set preview_max_x [some data goes here]

How do I format this so that nextcloud.occ inserts the variable into my php config properly? Any examples of a nextcloud.occ command would be very much appreciated.

@vegetaaaaaaa@lemmy.world
link
fedilink
English
2
edit-2
1Y

Really, https://help.nextcloud.com/ is the correct place to ask questions like these. Or you could check the docs:

So it should be something like sudo -u nextcloud /usr/bin/php /var/www/nextcloud.example.org/occ config:system:set preview_max_x --value="1500" (worked for me, standard PHP install, you will have to adapt it for your snap-based install). Or you can insert preview_max_x directly at the root of your config.php as shown in nextcloud’s sample config file above.

it set a string as an array, and triggered a bunch of php errors.

Always backup config.php.

@corroded@lemmy.world
creator
link
fedilink
English
11Y

Thanks! Adapting the command you gave to work with snap will be fairly easy. Regarding a backup of config.php, I’ve tried to do that, but with a snap install, I get a permission denied error when I try to enter the config directory, and you can’t “sudo cd.” I’ll try logging in as root or changing permissions.

Create a post

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don’t control.

Rules:

  1. Be civil: we’re here to support and learn from one another. Insults won’t be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it’s not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don’t duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

  • 1 user online
  • 31 users / day
  • 80 users / week
  • 216 users / month
  • 845 users / 6 months
  • 1 subscriber
  • 1.42K Posts
  • 8.13K Comments
  • Modlog