mirror of
https://github.com/nkanaev/yarr.git
synced 2025-05-25 13:39:22 +00:00
build docker v2.5
This commit is contained in:
parent
7ece385c66
commit
8042ae5694
@ -1,12 +1,13 @@
|
|||||||
FROM golang:1.21.5-alpine AS build
|
FROM golang:1.21.5-alpine AS build
|
||||||
RUN apk add --no-cache build-base git
|
RUN apk add build-base git
|
||||||
|
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
RUN git clone https://github.com/nkanaev/yarr.git .
|
COPY . .
|
||||||
ENV CGO_CFLAGS="-D_LARGEFILE64_SOURCE"
|
ENV CGO_CFLAGS="-D_LARGEFILE64_SOURCE"
|
||||||
RUN make build_default
|
RUN make build_linux
|
||||||
|
|
||||||
FROM alpine:3.19
|
FROM alpine:latest
|
||||||
COPY --from=build /src/_output/yarr /usr/local/bin/yarr
|
RUN apk add --no-cache ca-certificates && \
|
||||||
RUN mkdir /data
|
update-ca-certificates
|
||||||
CMD ["/usr/local/bin/yarr", "-addr", "0.0.0.0:7070", "-db", "/data/yarr.db"]
|
COPY --from=build /src/_output/linux/yarr /usr/local/bin/yarr
|
||||||
|
EXPOSE 7070
|
||||||
|
CMD ["/usr/local/bin/yarr", "-addr", "0.0.0.0:7070", "-db", "/data/yarr.db"]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user