diff --git a/seafile/Dockerfile b/seafile/Dockerfile index bb4ea4b..828fce0 100644 --- a/seafile/Dockerfile +++ b/seafile/Dockerfile @@ -28,19 +28,12 @@ future mysqlclient \ COPY scripts /scripts RUN chmod u+x /scripts/* -RUN mkdir -p /etc/my_init.d && \ - rm -f /etc/my_init.d/* && \ - cp /scripts/create_data_links.sh /etc/my_init.d/01_create_data_links.sh - - # Seafile WORKDIR /opt/seafile # For using TLS connection to LDAP/AD server with docker-ce. RUN find /opt/seafile/ \( -name "liblber-*" -o -name "libldap-*" -o -name "libldap_r*" -o -name "libsasl2.so*" \) -delete - EXPOSE 8080 8082 8001 - -CMD ["/sbin/my_init", "--", "/scripts/start.py"] +CMD ["/sbin/my_init", "--", "/scripts/start.sh"] diff --git a/seafile/scripts/start.sh b/seafile/scripts/start.sh new file mode 100644 index 0000000..6904da3 --- /dev/null +++ b/seafile/scripts/start.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +/scripts/create_data_links.sh + +mkdir -p /opt/seafile/seafile-server-latest/runtime +socat -v -d -d TCP-LISTEN:8001,fork,forever UNIX:/opt/seafile/seafile-server-latest/runtime/seafile.sock,forever & + +python3 /scripts/start.py