Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is it possible to separate photo storage (library) and thumbs/encoded-video #437

Open
stevetsanders opened this issue Sep 25, 2024 · 9 comments

Comments

@stevetsanders
Copy link

I'm wondering if it's possible to separate the photo storage location from the generated thumbnails/encoded-video location. I've seen some posts about separating them to take advantage of unraid parity for the actual photos but keep the thumbnails/encoded-video/other stuff on the cache. Ideally the setup would this I think

unraid array:

  • library folder

unraid cache

  • thumbs
  • encoded video
  • everything else

I know it's possible when setting up your own docker container but wondering if it's still possible when using the community app here

@hydazz
Copy link
Member

hydazz commented Sep 25, 2024

Yes, you can just map each folder to a different location on the host
so /photos/thumbs mounts to /mnt/cache/immich/thumbs
/photos/library mounts to /mnt/x/immich/thumbs
and so on...

@stevetsanders
Copy link
Author

Ah gotcha, so adding those additional subdirectories would be done via adding another path?

image

@dilirity
Copy link

dilirity commented Sep 28, 2024

Wondering the same thing! Is such a thing possible within unraid with the community app?

I couldn't find a variable that's used for the thumbnails directory.

EDIT:

I think I managed to do it as per @hydazz's suggestion (not sure how correct it is though):

image

For reference, this is my /photos and /libraries mounts:

image

@hydazz
Copy link
Member

hydazz commented Sep 29, 2024

you'll want to try to avoid mounting a mount inside a mount, ie above you have /mnt/user/photos_immich mounted to /photos, but you also have /mnt/user/appdata/immich/thumbs mounted inside /photos - not the end of the world, but may cause issues

@dilirity
Copy link

I see, thanks.

What's the proper way of doing it?

@martabal
Copy link
Collaborator

You need to add these volumes (assuming you are using the storage template):

  • /mnt/user/photos_immich/photos/library
  • /mnt/user/appdata/immich/thumbs/photos/thumbs
  • /mnt/user/appdata/immich/profile/photos/profile
  • /mnt/user/appdata/immich/encoded-video/photos/encoded-video
  • /mnt/user/appdata/immich/upload/photos/upload

based on https://immich.app/docs/administration/backup-and-restore#filesystem

@dilirity
Copy link

dilirity commented Sep 29, 2024

I am not using the storage template.

Storage template engine was turned off by default so I didn't turn it on.

EDIT:

I had no idea I could edit the Path: /photos: variable 😅

Here are my variables:

VARIABLE NAME: Host Path -> Container Path

  • Path: /photos:: /mnt/user/photos_immich/ -> /photos/library
  • Path: /libraries:: /mnt/user/pictures/ -> /libraries
  • thumbnails: /mnt/user/appdata/immich/thumbs -> /photos/thumbs
  • encoded-video: /mnt/user/appdata/immich/encoded-video -> /photos/encoded-video
  • profile: /mnt/user/appdata/immich/profile -> /photos/profile
  • upload: /mnt/user/appdata/immich/upload -> /photos/upload

I also had to create an .immich file in each of them to get immich to work properly.

@martabal
Copy link
Collaborator

I am not using the storage template.

If you're not using the storage template, then you need to change that volume:

  • upload: /mnt/photos_immich/photos/upload

and remove /photos/library

@dilirity
Copy link

Awesome! Thanks @martabal!

Here's the updated mount list in case anyone needs to do a similar setup:

VARIABLE NAME: Host Path -> Container Path

  • Path: /photos:: /mnt/user/photos_immich/ -> /photos/upload
  • Path: /libraries:: /mnt/user/pictures/ -> /libraries
  • thumbnails: /mnt/user/appdata/immich/thumbs -> /photos/thumbs
  • encoded-video: /mnt/user/appdata/immich/encoded-video -> /photos/encoded-video
  • profile: /mnt/user/appdata/immich/profile -> /photos/profile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants