FROM rust:1.34 AS riffol_build RUN cargo install --git https://github.com/shimunn/riffol.git --branch 32b FROM nginx:mainline VOLUME /opt/seafile EXPOSE 80 10001 12001 8000 8080 8082 ENV SEAF=/opt/seafile COPY requirements.txt /tmp/requirements.txt RUN apt update && apt install locales -y && apt install -y --no-install-recommends procps openssl python2.7 sqlite3 python-mysqldb python-pil curl libjansson4 libfuse2 python-pip python-pip-whl python-setuptools \ && pip install -r /tmp/requirements.txt && apt remove -y python-pip \ && rm -rf /var/lib/apt/lists/* /tmp/requirements.txt #ENV RIFFOL_VERSION libc-2.24 #ENV RIFFOL_HASH e6aea0a91abe74dc0892b0814a0485f16ce8b738b4672b4980b15a398c013e974d5d1b6c27eed69899196cc21014e407f7ff74ee5636a8690ebd639fe0ca5abb #RUN curl -L https://github.com/riboseinc/riffol/releases/download/0.1.0/riffol-$RIFFOL_VERSION.tar.gz -o /tmp/riffol-$RIFFOL_VERSION.tar.gz && \ # echo "$RIFFOL_HASH /tmp/riffol-$RIFFOL_VERSION.tar.gz" | sha512sum --check && \ # tar -xvzf /tmp/riffol-$RIFFOL_VERSION.tar.gz -C /usr/sbin/ && \ # rm /tmp/riffol-$RIFFOL_VERSION.tar.gz COPY --from=riffol_build /usr/local/cargo/bin/riffol /usr/sbin/ RUN ln -s /opt/seafile/seafile-server-latest/seafile.sh /usr/bin/seafile && \ ln -s /opt/seafile/seafile-server-latest/seahub.sh /usr/bin/seahub && \ ln -s /opt/seafile/pids /var/run/seafile COPY riffol.conf /etc/riffol.conf COPY conf /opt/seafile/conf COPY conf /etc/seafile COPY nginx /etc/nginx COPY scripts/upgrade.py /usr/local/sbin/upgrade COPY scripts/setup.sh /usr/bin/setup RUN ulimit -n 30000 && mkdir -p $SEAF/pids && \ chmod +x /usr/local/sbin/upgrade /usr/bin/setup ENV SEAF_UPGRADE_INTERVAL=3 ENTRYPOINT ["/usr/sbin/riffol", "-f", "/etc/riffol.conf"]