Closed mainboarder closed 1 year ago
We need more error logs to troubleshoot problems.
Please add the following contents to the /opt/seafile/conf/gunicorn.py
configuration file.
# Log
accesslog = '/opt/seafile/logs/gunicorn-access.log'
errorlog = '/opt/seafile/logs/gunicorn-error.log'
And then execute /scripts/start.py &
. There will be more detailed errors in the /opt/seafile/logs/gunicorn-error.log
log file.
Hi,
I did some testing now.
First of all, I changed seatable to seafile in all of your code, as I work with seafile and there is no seatable directory under /opt
.
In the meantime I updated to the latest version. From 9.0.7 to 9.0.9.
First there was an error, that the user (root) running the script is not the owner of /shared/seafile/seafile-data
. So I chown the underlying host-fs directory. This might be missing in the manual. And I would add it, when I get my installation migrated to docker. This one looks new with version 9.0.9.
Afterwards it now looks like:
root@5882b399275a:/opt/seafile# /scripts/enterpoint.sh
2022-10-08 13:07:14 Nginx ready
2022-10-08 13:07:14 This is an idle script (infinite loop) to keep container running.
[2022-10-08 13:07:14] Skip running setup-seafile-mysql.py because there is existing seafile-data folder.
Starting seafile server, please wait ...
** (process:153): WARNING **: 13:07:15.111: seafile-controller.c(586): invalid config_dir: /opt/seafile/ccnet
** (process:153): WARNING **: 13:07:15.112: seafile-controller.c(64): seaf-controller exited with code 1
Failed to start seafile server
Traceback (most recent call last):
File "/scripts/start.py", line 86, in <module>
main()
File "/scripts/start.py", line 71, in main
call('{} start'.format(get_script('seafile.sh')))
File "/scripts/utils.py", line 70, in call
return subprocess.check_call(*a, **kw)
File "/usr/lib/python3.8/subprocess.py", line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '/opt/seafile/seafile-server-9.0.9/seafile.sh start' returned non-zero exit status 1.
Again the ccnet error. Good thing: I forgot about it and so I now did not copy the directory, but I created it in the container. Now it works.
But this seems to be a bug for me. In the container should /opt/seafile/ccnet
exist, mounted from Host or at least it should be in the manual, shouldn't it? Or is this special with my installation? I did not find this path in my config files.
Tl;dr:
chown -R root:root <HOST-FS/home/seafile/seafile-data> #if you use method 2 here: https://manual.seafile.com/docker/non_docker_to_docker/#method-2
docker-compose up -d
docker exec -ti seafile mkdir /opt/seafile/ccnet
docker-compose down && docker-compose up -d
Test with:
docker exec -ti seafile /bin/bash
/opt/seafile/seafile-server-latest/seahub.sh stop && /opt/seafile/seafile-server-latest/seafile.sh stop
/scripts/enterpoint.sh
Sorry I wrote the wrong path. (> _ <)
/opt/seafile/ccnet is a symbolic link generated by the startup script. You can create the real ccnet directory in the Host.
eg: mkdir /opt/seafile/shared/seafile/ccnet
You can find the parent path in docker-compose.yml: seafile: volumes:
I can confirm everything works now! Thank you!
There seem to be multiple errors in the documentation for migrating from non docker:
So I copied the ccnet directory, chowned to -R root:root and added
- /opt/seafile-data/ccnet:/opt/seafile/ccnet
to volumes in docker-compose -> This is different from the manualAfterwards it looked better, but seahub is not able to run. I got a Bad Gateway from nginx. So I entered the container:
The seahub log is empty.
running on debian 10. with seafile 9.0.7 (docker) comming from 9.0.7 non-docker.
How do I get seafile to work in docker?