Add simple Dockerfile for running mbusd containerized (#79)

* init

* simplify

* explicit gcc not needed

* do not clone repository, copy source from cwd (or we cannot build releases)
This commit is contained in:
Jakob Schlyter 2021-11-15 12:04:04 +01:00 committed by GitHub
parent cb9576a5a0
commit 55889a7292
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

10
Dockerfile Normal file
View File

@ -0,0 +1,10 @@
FROM alpine:latest AS build
RUN apk add --no-cache alpine-sdk cmake
COPY . /mbusd
WORKDIR /mbusd/build
RUN cmake -DCMAKE_INSTALL_PREFIX=/usr .. && make && make install
FROM alpine:latest AS scratch
ENV QEMU_EXECVE=1
COPY --from=build /usr/bin/mbusd /usr/bin/mbusd
ENTRYPOINT ["/usr/bin/mbusd", "-d", "-L", "-", "-c", "/etc/mbusd.conf"]