FROM golang:1.19 AS build ARG HTTP_PROXY= ARG HTTPS_PROXY= ARG http_proxy= ARG https_proxy= ARG NODE_MAJOR=16 RUN apt-get update && apt-get install -y build-essential git bash curl ca-certificates gnupg RUN echo 'Package: nodejs\nPin: origin deb.nodesource.com\nPin-Priority: 600' > /etc/apt/preferences.d/nodesource \ && mkdir -p /etc/apt/keyrings \ && curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg \ && echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \ && apt-get update \ && apt-get install -y nodejs COPY . /src WORKDIR /src RUN make deps \ && make ARCH_TARGETS=amd64 release FROM busybox COPY --from=build /src/release/server-linux-amd64 /app WORKDIR /app COPY misc/dokku/CHECKS /client/CHECKS EXPOSE 80 VOLUME /data ENV GUESSTIMATE_HTTP_ADDRESS=:80 ENV GUESSTIMATE_HTTP_PUBLIC_DIR=/app/public ENV GUESSTIMATE_DATA_PATH=/data/guesstimate.db CMD ["/app/bin/server", "-config", "config.yml"]