From ca96a23197e3d1dcb11b68cc1d15aafa516d5ac9 Mon Sep 17 00:00:00 2001 From: s-ol Date: Tue, 8 Oct 2019 19:04:21 +0200 Subject: realtime server Dockerfile --- Dockerfile | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) (limited to 'Dockerfile') diff --git a/Dockerfile b/Dockerfile index af0f4b5..f8c158b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,12 +1,19 @@ -FROM nickblah/lua:5.3-luarocks-stretch AS build-env -RUN echo "deb http://ppa.launchpad.net/jonathonf/tup/ubuntu xenial main" >/etc/apt/sources.list.d/tup.list -RUN apt-get update -RUN apt-get install -y --allow-unauthenticated build-essential tup sassc libmarkdown2-dev -RUN luarocks install moonscript +FROM nickblah/lua:5.3-luarocks-stretch + +RUN echo "deb http://ppa.launchpad.net/jonathonf/tup/ubuntu xenial main" \ + >/etc/apt/sources.list.d/tup.list +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + build-essential m4 tup sassc \ + libmarkdown2-dev libsqlite3-dev libssl-dev RUN luarocks install discount DISCOUNT_INCDIR=/usr/include/x86_64-linux-gnu -COPY . /build -RUN cd /build && tup init && tup generate --config tup.docker.config build.sh && ./build.sh +RUN luarocks install moonscript +RUN luarocks install sqlite3 +RUN luarocks install http + +COPY . /code +WORKDIR /code +RUN tup init && tup generate --config tup.docker.config build-static.sh && ./build-static.sh -FROM nginx:alpine -COPY --from=build-env /build/root /usr/share/nginx/html -RUN chmod 555 -R /usr/share/nginx/html +EXPOSE 8000 +ENTRYPOINT ["moon", "build/server.moon", "/db.sqlite3", "0.0.0.0", "8000"] -- cgit v1.2.3