goal
I have deployed seafil via docker compose on ubuntu using the docker compose below. I wish to add an external SMB share to seafile to use for a library on an location other than where im storing my docker compose apps and in none block storage.
Reasoning
- Reasoning for this is converting 20+ tb of data in block storage is quite a scary concept - I need to have access to the files as normal storage type from the server not just the clients.
- The nvme where im storing the seafile config data (and all my other docker compose apps in my vm) doesnt have room for storing my media i wish to sync and moving this whole app directory to the location where the data is seems archaic.
- Requiring me to use seafile as my ownly file host as i wouldnt be able to read the server storage in any other way other than seafile tech seems dangerous, ive had seafile break on me before.
- I would like to have other services such as pingvin, filebrowser and nextcloud access the same data as seafile
docker compose
services:
db:
image: mariadb:10.11
container_name: seafile-mysql
environment:
- MYSQL_ROOT_PASSWORD=PASSWORD# Requested, set the root's password of MySQL service.
- MYSQL_LOG_CONSOLE=true
- MARIADB_AUTO_UPGRADE=1
volumes:
- /docker/seafile/mysql-db:/var/lib/mysql # Requested, specifies the path to MySQL data persistent store.
networks:
- seafile-net
memcached:
image: memcached:1.6.18
container_name: seafile-memcached
entrypoint: memcached -m 256
networks:
- seafile-net
seafile:
image: seafileltd/seafile-mc:latest
container_name: seafile
ports:
- "9080:80"
# - "443:443" # If https is enabled, cancel the comment.
volumes:
- /docker/seafile/data:/shared
# - /mnt/Personal_Library:/shared/seafile/seafile-data/Personal_Library:rw
- /mnt/Personal_Library:/shared/seafile/seafile-data/storage/blocks/87c1e89a-71c9-463d-b73e-d56b72dbca05
# - /mnt/Personal_Library:/shared/seafile/seafile-data
environment:
- DB_HOST=db
- DB_ROOT_PASSWD=PASSWORD# Requested, the value should be root's password of MySQL service.
- TIME_ZONE=Europe/London # Optional, default is UTC. Should be uncomment and set to your local time zone.
- SEAFILE_ADMIN_EMAIL=EMAIL.com # Specifies Seafile admin user, default is 'me@example.com'.
- SEAFILE_ADMIN_PASSWORD=PASSWORD# Specifies Seafile admin password, default is 'asecret'.
- SEAFILE_SERVER_LETSENCRYPT=false # Whether to use https or not.
- SEAFILE_SERVER_HOSTNAME=seafile.DOMAIN.com:9080 # Specifies your host name if https is enabled.
depends_on:
- db
- memcached
networks:
- seafile-net
networks:
seafile-net:
what ive tried so far
I have mounted with full read and write access the location which i would like to use as a library however
volumes:
- /docker/seafile/data:/shared
# - /mnt/Personal_Library:/shared/seafile/seafile-data/Personal_Library:rw
- /mnt/Personal_Library:/shared/seafile/seafile-data/storage/blocks/87c1e89a-71c9-463d-b73e-d56b72dbca05
# - /mnt/Personal_Library:/shared/seafile/seafile-data
Trouble shooting
- i have checked that the mount point is owned by seafile
- i have accessed the container to see if the library mount i added is visible and mounted and that i can edit the files seen in the library (and make new files)
- i have tried mounting to an existing library ID however the existing data in the folder was not visible but new block data could be added by making new files in the gui.
- i have tried tried using seafile cli commands to mount a library ID to the storage location but the cli commands were not recognised;
i am slightly confused by how data can maintain its format within the storage locations on my windows machine
root@329a3e6c192b:/opt/seafile# seaf-cli attach -l 94fd6142-a7ff-411b-8249-a6354580ff73 /opt/seafile/seafile-data/Person
al_Library
bash: seaf-cli: command not found
root@329a3e6c192b:/opt/seafile#
- ive tried editing the conf file to change the loction of the existing data however this didnt work either, there is no location defined in the conf file.