This repository has been archived on 2021-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
docker-diaspora/Dockerfile

47 lines
1.4 KiB
Docker
Raw Permalink Normal View History

2017-11-24 19:18:38 +01:00
FROM ruby:2.2-slim-jessie
2017-11-23 20:21:10 +01:00
2017-11-23 22:15:12 +01:00
ENV UID=991 GID=991 \
2017-11-24 19:18:38 +01:00
NPROC=2
2017-11-23 20:21:10 +01:00
2017-11-24 19:18:38 +01:00
RUN echo "deb http://ftp.debian.org/debian jessie-backports main contrib non-free" >> /etc/apt/sources.list \
&& export BUILD_DEPS=" build-essential \
libssl-dev \
libcurl4-openssl-dev \
libxml2-dev libxslt-dev \
libmagickwand-dev \
libpq-dev" \
&& apt-get update \
&& apt-get install -y --no-install-recommends ${BUILD_DEPS} \
ruby \
imagemagick \
curl \
libcurl3 \
openssl \
ghostscript \
git \
nginx-light \
2017-11-24 20:39:02 +01:00
dnsutils \
2017-11-24 20:40:23 +01:00
ca-certificates \
2017-11-24 19:18:38 +01:00
&& curl -sL https://deb.nodesource.com/setup_6.x | bash - \
&& apt-get -y install -y nodejs --no-install-recommends \
2017-11-23 20:21:10 +01:00
&& gem install bundler \
&& git clone -b master https://github.com/diaspora/diaspora.git /diaspora \
&& cd /diaspora \
2017-11-24 12:37:34 +01:00
&& chmod +x script/server \
2017-11-24 02:06:14 +01:00
&& bin/bundle config --global silence_root_warning 1 \
2017-11-24 02:04:02 +01:00
&& bin/bundle config timeout 120 \
2017-11-24 13:13:29 +01:00
&& bin/bundle install --jobs $(nproc) --retry 4 --without test development --with postgresql \
2017-11-24 19:18:38 +01:00
&& apt-get remove --purge --yes ${BUILD_DEPS} \
&& apt-get autoremove -y \
&& apt-get clean \
&& rm -rf /diaspora/.git /tmp/* /var/lib/apt/lists/* /var/cache/debconf/*-old /usr/share/man/?? /usr/share/man/??_*
2017-11-24 12:37:34 +01:00
COPY rootfs/ /
2017-11-24 19:18:38 +01:00
RUN chmod +x /usr/local/bin/startup
2017-11-23 21:18:37 +01:00
2017-11-23 21:13:20 +01:00
VOLUME ["/config", "/diaspora/public"]
2017-11-23 23:00:50 +01:00
EXPOSE 8080
2017-11-23 20:21:10 +01:00
ENTRYPOINT [ "/usr/local/bin/startup" ]
CMD ["/bin/s6-svscan", "/etc/s6.d"]