2017-11-24 00:14:41 +01:00
|
|
|
FROM xataz/nginx
|
2017-11-23 20:21:10 +01:00
|
|
|
|
2017-11-23 22:15:12 +01:00
|
|
|
ENV UID=991 GID=991 \
|
|
|
|
NPROC=2
|
2017-11-23 20:21:10 +01:00
|
|
|
|
|
|
|
RUN export BUILD_DEPS="build-base \
|
|
|
|
libxml2-dev \
|
|
|
|
libxslt-dev \
|
|
|
|
curl-dev \
|
|
|
|
git \
|
2017-11-24 00:20:19 +01:00
|
|
|
ruby-dev \
|
2017-11-24 01:31:04 +01:00
|
|
|
libffi-dev \
|
2017-11-24 00:49:35 +01:00
|
|
|
libtirpc-dev \
|
2017-11-24 13:28:13 +01:00
|
|
|
imagemagick-dev " \
|
2017-11-23 21:02:12 +01:00
|
|
|
&& apk add -U ${BUILD_DEPS} \
|
2017-11-23 20:21:10 +01:00
|
|
|
libressl \
|
|
|
|
imagemagick \
|
|
|
|
curl \
|
|
|
|
ghostscript \
|
|
|
|
git \
|
|
|
|
postgresql-client \
|
|
|
|
su-exec \
|
|
|
|
s6 \
|
2017-11-23 21:28:09 +01:00
|
|
|
ca-certificates \
|
2017-11-23 22:27:35 +01:00
|
|
|
coreutils \
|
2017-11-23 22:38:54 +01:00
|
|
|
gcc \
|
2017-11-24 00:12:36 +01:00
|
|
|
nodejs \
|
|
|
|
nodejs-npm \
|
2017-11-24 01:22:26 +01:00
|
|
|
libffi \
|
2017-11-24 00:12:36 +01:00
|
|
|
ruby \
|
|
|
|
ruby-irb \
|
|
|
|
ruby-rdoc \
|
2017-11-24 13:33:16 +01:00
|
|
|
ruby-rake \
|
2017-11-24 13:56:44 +01:00
|
|
|
sigar \
|
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 01:56:11 +01:00
|
|
|
&& rm Gemfile.lock \
|
2017-11-24 12:37:34 +01:00
|
|
|
&& chmod +x script/server \
|
2017-11-24 12:46:43 +01:00
|
|
|
&& echo "**** GEMFILE ****" \
|
|
|
|
&& cat Gemfile \
|
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 02:04:02 +01:00
|
|
|
&& apk del ${BUILD_DEPS} \
|
|
|
|
&& rm -rf /tmp/* /var/cache/apk/* /tmp/* /root/.gnupg /root/.cache/ /diaspora/.git \
|
|
|
|
&& chmod +x /usr/local/bin/startup \
|
|
|
|
&& chmod +x /etc/s6.d/diaspora/run
|
2017-11-24 12:37:34 +01:00
|
|
|
|
|
|
|
COPY rootfs/ /
|
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"]
|