How to create multiple docker volumes for SeaFile?

Hi

How can I create different volumes that can be used for SeaFile ?

Currently one can only specify one location for all the storage that SeaFile needs

E.g. I would like to run SeaFile oa a local folder on my Docker host but the files that is uploaded by users I want to store in a different location e.g. a network share

You can use the following steps:

  1. Finish deploying seafile
  2. move /opt/seafile-data/seafile/seafile-data to a location in NFS like “/shared/seafile-data”
  3. Modify seafile-server.yml adding a new map:/shared/seafile-data:/shared/seafile/seafile-data

Remember to add “no_root_squash” option when mount the NFS share to the server. Otherwise, Seafile will not have the permission to write to the NFS share.