Remove site building
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Stefan Hoffmann 2019-12-02 18:23:02 +00:00
parent 4828b1672f
commit c92cb6b356

View File

@ -3,10 +3,4 @@ MAINTAINER Freifunk Rhein-Sieg e.V. <technik@freifunk-rhein-sieg.net>
EXPOSE 80
WORKDIR /project
RUN apt-get update -y && apt-get install -y git ruby ruby-dev rubygems build-essential cron
RUN gem install bundle
RUN git init && git remote add origin https://git.freifunk-rhein-sieg.net/Freifunk-Rhein-Sieg/freifunk-rhein-sieg.net.git
RUN touch /etc/cron.d/update && touch /srv/update.sh && chmod 775 /srv/update.sh && chmod 644 /etc/cron.d/update && touch /var/log/cron.log
RUN echo "cd /project && git pull origin master && /usr/local/bin/jekyll build && rm -rf /usr/share/nginx/html/* && cp -r _site/* /usr/share/nginx/html" > /srv/update.sh
RUN echo "*/30 * * * * root /srv/update.sh >> /var/log/cron.log 2>&1" > /etc/cron.d/update
ENTRYPOINT git fetch && git pull origin master && bundle install && bundle exec jekyll build && rm -rf /usr/share/nginx/html/* && cp -r _site/* /usr/share/nginx/html && echo "ready" && /etc/init.d/cron start && nginx -g "daemon off;"
ENTRYPOINT nginx -g "daemon off;"