完全按照教程部署的,仅修改了caddy的主机映射端口,180:80,1443:443,防火墙也放开了180,1443,6233几个端口。在.env文件中将seafile.example.com字段改为了主机的局域网ip地址。部署前已在/opt/seafile下载好了各yml文件,在/opt/seafile-data/seafile/conf目录设置了seafdav.conf seafile.conf seahub_settings.py三个文件。遇到以下问题:
问题1:lucaslorentz/caddy-docker-proxy:2.9镜像,docker ps的STATUS显示unhealthy
健康检查日志显示:
OCI runtime exec failed: exec failed: unable to start container process: exec: "/bin/sh": stat /bin/sh: no such file or directory: unknown。
问题2:notification-server容器一直重启,日志显示:
[ERROR] Failed to connected to mysql: Error 1045: Access denied for user 'seafile'@'172.18.0.7' (using password: YES)。
进入mysql容器(即mariadb:10.11)检查发现并没有seafile用户。
mysql容器日志如下:
2024-12-31 15:18:28+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.11.10+maria~ubu2204 started.
2024-12-31 15:18:28+00:00 [Warn] [Entrypoint]: /sys/fs/cgroup///memory.pressure not writable, functionality unavailable to MariaDB
2024-12-31 15:18:28+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
2024-12-31 15:18:28+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.11.10+maria~ubu2204 started.
2024-12-31 15:18:29+00:00 [Note] [Entrypoint]: MariaDB upgrade not required
2024-12-31 15:18:29 0 [Note] Starting MariaDB 10.11.10-MariaDB-ubu2204 source revision 3d0fb150289716ca75cd64d62823cf715ee47646 server_uid 5WChtxxgV/VZkvpXNaDAgEZEcZs= as process 1
2024-12-31 15:18:29 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2024-12-31 15:18:29 0 [Note] InnoDB: Number of transaction pools: 1
2024-12-31 15:18:29 0 [Note] InnoDB: Using crc32 + pclmulqdq instructions
2024-12-31 15:18:29 0 [Note] mariadbd: O_TMPFILE is not supported on /tmp (disabling future attempts)
2024-12-31 15:18:29 0 [Warning] mariadbd: io_uring_queue_init() failed with errno 1
2024-12-31 15:18:29 0 [Warning] InnoDB: liburing disabled: falling back to innodb_use_native_aio=OFF
2024-12-31 15:18:29 0 [Note] InnoDB: Initializing buffer pool, total size = 128.000MiB, chunk size = 2.000MiB
2024-12-31 15:18:29 0 [Note] InnoDB: Completed initialization of buffer pool
2024-12-31 15:18:29 0 [Note] InnoDB: File system buffers for log disabled (block size=512 bytes)
2024-12-31 15:18:29 0 [Note] InnoDB: End of log at LSN=46862
2024-12-31 15:18:29 0 [Note] InnoDB: 128 rollback segments are active.
2024-12-31 15:18:29 0 [Note] InnoDB: Setting file './ibtmp1' size to 12.000MiB. Physically writing the file full; Please wait ...
2024-12-31 15:18:29 0 [Note] InnoDB: File './ibtmp1' size is now 12.000MiB.
2024-12-31 15:18:29 0 [Note] InnoDB: log sequence number 46862; transaction id 14
2024-12-31 15:18:29 0 [Note] Plugin 'FEEDBACK' is disabled.
2024-12-31 15:18:29 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2024-12-31 15:18:29 0 [Warning] You need to use --log-bin to make --expire-logs-days or --binlog-expire-logs-seconds work.
2024-12-31 15:18:29 0 [Note] InnoDB: Buffer pool(s) load completed at 241231 15:18:29
2024-12-31 15:18:29 0 [Note] Server socket created on IP: '0.0.0.0'.
2024-12-31 15:18:29 0 [Note] Server socket created on IP: '::'.
2024-12-31 15:18:29 0 [Note] mariadbd: ready for connections.
Version: '10.11.10-MariaDB-ubu2204' socket: '/run/mysqld/mysqld.sock' port: 3306 mariadb.org binary distribution
2024-12-31 15:18:29 3 [Warning] Access denied for user 'seafile'@'172.18.0.8' (using password: YES)
2024-12-31 15:18:30 4 [Warning] Access denied for user 'seafile'@'172.18.0.8' (using password: YES)
2024-12-31 15:18:31 5 [Warning] Access denied for user 'seafile'@'172.18.0.8' (using password: YES)
2024-12-31 15:18:32 6 [Warning] Access denied for user 'seafile'@'172.18.0.8' (using password: YES)
2024-12-31 15:18:34 9 [Warning] Access denied for user 'seafile'@'172.18.0.8' (using password: YES)
seafile的日志显示如下:
*** Running /etc/my_init.d/01_create_data_links.sh...
*** Booting runit daemon...
*** Runit started as PID 18
*** Running /scripts/enterpoint.sh...
2024-12-31 23:18:29 Nginx ready
2024-12-31 23:18:29 This is an idle script (infinite loop) to keep container running.
Traceback (most recent call last):
File "/scripts/start.py", line 94, in <module>
main()
File "/scripts/start.py", line 58, in main
wait_for_mysql()
File "/scripts/utils.py", line 281, in wait_for_mysql
db_host = cp.get('database', 'host')
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/configparser.py", line 759, in get
d = self._unify_values(section, vars)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/configparser.py", line 1132, in _unify_values
raise NoSectionError(section) from None
configparser.NoSectionError: No section: 'database'
seafile容器内执行env显示.env文件中设置的各个环境变量均存在。
请问各位部署的时候有没有遇到相同问题,是如何解决的?多谢!
已经试过了社区里https://bbs.seafile.com/t/topic/20966这个帖子的方法,未能解决。
另外,中文的pro版本部署教程中下载yml文件的命令写错了,下载的是ce版的。英文教程中没有错
wget -O .env https://manual.seafile.com/12.0/docker/ce/env
wget https://manual.seafile.com/12.0/docker/ce/seafile-server.yml