docker-seafile-client/Dockerfile

24 lines
855 B
Docker
Raw Normal View History

2019-04-13 18:45:06 +00:00
FROM python:3-slim
2018-04-18 16:32:41 +00:00
RUN apt-get update && apt-get install gnupg -y && rm -rf /var/lib/apt/lists/*
2018-04-18 16:32:41 +00:00
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 8756C4F765C9AC3CB6B85D62379CE192D401AB61 && \
2019-08-14 09:14:50 +00:00
echo deb http://deb.seadrive.org buster main | tee /etc/apt/sources.list.d/seafile.list && \
2018-04-18 16:32:41 +00:00
apt-get update -y && \
apt-get install -y seafile-cli procps curl grep && \
2018-04-18 16:32:41 +00:00
rm -rf /var/lib/apt/lists/*
WORKDIR /seafile-client
2019-04-13 18:45:06 +00:00
COPY requirements.txt ./
RUN pip install --no-cache-dir -r requirements.txt
2018-04-18 16:32:41 +00:00
COPY seafile_client ./seafile_client/
COPY start.py ./start.py
2018-04-18 16:32:41 +00:00
2019-04-13 18:45:06 +00:00
RUN chmod +x /seafile-client/start.py && \
2018-04-18 16:32:41 +00:00
useradd -U -d /seafile-client -s /bin/bash seafile && \
usermod -G users seafile && \
chown seafile:seafile -R /seafile-client && \
su - seafile -c "seaf-cli init -d /seafile-client"
2019-04-13 18:45:06 +00:00
CMD ["./start.py"]