Skip to content

Commit

Permalink
Add Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
defaultpage committed Feb 5, 2023
1 parent dff8a57 commit e55119f
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
FROM alpine:latest as builder

WORKDIR /hlsdl-repo

RUN --mount=type=cache,target=/var/cache/apk \
apk add gcc make curl-dev libc-dev

COPY makefile hlsdl.1 LICENSE ./

COPY src src

RUN make && make install && make clean


FROM alpine:latest

RUN --mount=type=cache,target=/var/cache/apk \
apk add curl

RUN mkdir -p /var/hlsdl/data && chown 1000:1000 /var/hlsdl/data

USER 1000:1000

VOLUME /var/hlsdl/data

WORKDIR /var/hlsdl/data

COPY --from=builder /usr/local/bin/hlsdl /usr/local/bin/

CMD ["hlsdl"]

0 comments on commit e55119f

Please sign in to comment.