Docker is becoming the de-facto standard of shipping server softwares, and now and then we are asked the question “Do you support running seafile server in docker?”. We believe docker can make it much easier to deploy a Seafile server on your servers and keep it updated. Now it is ready for testing.
Using docker, you can get a seafile sever up and running with only a few minutes. Letsencrypt verification is also done automatically if you want.
Getting Started
Please follow the getting started section in the README.
Current Limitations
Doesn’t support Seafile Pro Server yet
Roadmap
Support Seafile Pro Server
Special Thanks
Lots the design of seafile-docker is borrowed from the excellent discourse-docker project (this forum is powered by discourse and we really enjoy using it). Thanks for their insipiration!
Okay, that’s something I’m not aware of. The official docker images are all for x86_64, and IIUC you need to build dedicated images for arm architecture. The Dockerfile for seafile image is quite straight forward, and I think we can leave the rpi+docker support to the community.
As mentioned above, this isn’t true - ResinOS for example has published prebuilt disk images for Raspberry Pi and a whole bunch of other platforms too, all with Docker pre-bundled, expressly built to run Docker on non-x86 platforms. Docker for smaller machines is a pretty quickly growing corner right now (disclaimer: I work for Resin.io, building a docker-based IoT platform, so I might be a bit biased there). I’ve got a raspberry pi at home running Docker to more easily manage and host Kodi though for example, it’s a good model.
Anyway, I’m super interested in this running this myself on a raspberry pi too @saljut7 - let me know if you get anywhere (or if you want any help!)
I have a question. How can I change the /shared docker volume to another location instead of /var/seafile/shared ? To something like /media/sdb/shared .
I’m assuming I would have to edit the launcher if I am not mistaken?
Mahalo.
Edit: Disregard I found it. I made a change to the launcher sharedir=/media/sdb/shared
I got the hint from seafile sales department to use docker instead to run a vm on my asustor NAS Server.
I was able to download the Image, but don’t know now I have to do to get a running docker VM.
When call the Image in UI for docker I have several things which I can setup or have to setup.
Here are some Screesnhots, maybe some one can describe what I have to do.
I developed a similar container in this GitHub project: https://github.com/stonemaster/docker-seafile-server
The container supports automatic updates and has a focus on an easy setup experience. Raspberry Pi isn’t supported as of yet but pull requests are always welcome!
[root@idbear seafile]# ./launcher bootstrap
Rebuilding mysql data dir
Starting mysqld
Waiting for mysqld to come online
Fixing root password
Shutting down mysqld
[2017-06-21 10:53:43] Generating local Dockerfile …
[2017-06-21 10:53:45] Now running setup-seafile-mysql.py in auto mode.
Checking python on this machine …
Checking python module: setuptools … Done.
Checking python module: python-imaging … Done.
Checking python module: python-mysqldb … Done.
verifying password of user root …
verifying password of user root … done
This is your configuration
server name: seafile
server ip/domain: 192.168.1.160
seafile data dir: /opt/seafile/seafile-data
fileserver port: 8082
database: create new
ccnet database: ccnet_db
seafile database: seafile_db
seahub database: seahub_db
database user: seafile
Generating ccnet configuration …
done
Successly create configuration dir /opt/seafile/ccnet.
Generating seafile configuration …
Done.
done
Generating seahub configuration …
Now creating seahub database tables …
Error: Failed to prepare seahub avatars dir: [Errno 39] Directory not empty: ‘/opt/seafile/seafile-server-6.0.9/seahub/media/avatars/groups’
Traceback (most recent call last):
File “/scripts/bootstrap.py”, line 196, in
main()
File “/scripts/bootstrap.py”, line 189, in main
init_seafile_server()
File “/scripts/bootstrap.py”, line 141, in init_seafile_server
call(’{} auto -n seafile’.format(setup_script), env=env)
File “/scripts/utils/init.py”, line 68, in call
return subprocess.check_call(*a, **kw)
File “/usr/lib/python2.7/subprocess.py”, line 541, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command ‘/opt/seafile/seafile-server-6.0.9/setup-seafile-mysql.sh auto -n seafile’ returned non-zero exit status 1
I have the same problem.
It’s not work. When i run bootstrap again it write “Failed to connect to mysql server”
From scratch same error(((
Centos 7.4, Docker version 17.06.2-ce, build cec0b72