1
0
mirror of synced 2026-01-14 07:49:47 +00:00
Interlisp.medley/Dockerfile
Abe Jellinek fbda23486f Cut image size to 356 MB, down from 2 GB
Using a Docker feature called "multi-stage builds" [1], we build Maiko in
one image, then create a new one into which we copy the final binary but
not sources and headers. Both images are still Ubuntu-based (todo), but
the <400 MB final product is much slimmer than what we had before.

[1]: https://docs.docker.com/develop/develop-images/multistage-build/
2020-11-02 14:56:45 -08:00

25 lines
580 B
Docker

FROM ubuntu:focal
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y build-essential clang libx11-dev
COPY maiko /build/
WORKDIR /build/bin
RUN rm -rf /build/linux*
RUN ./makeright x
FROM ubuntu:focal
ENV DEBIAN_FRONTEND=noninteractive
EXPOSE 5900
RUN apt-get update && apt-get install -y tightvncserver
RUN mkdir /app
WORKDIR /app
COPY loadups ./
COPY --from=0 /build/linux.x86_64/* ./
RUN adduser --disabled-password --gecos "" medley
USER medley
ENTRYPOINT USER=medley Xvnc -geometry 1270x720 :0 & DISPLAY=:0 /app/ldex -g 1280x720 xfull35.sysout