Last active
June 1, 2020 11:32
-
-
Save u1and0/ecb79943b982b92c9476508f83053e4b to your computer and use it in GitHub Desktop.
draft for Dockerfile at grep-server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Usage: | |
| # ``` | |
| # $ docker run -d --rm u1and0/grep-server [options] | |
| # ``` | |
| FROM golang:buster AS builder | |
| COPY ./main.go /go/src/github.com/u1and0/grep-server/main.go | |
| COPY ./go.mod /go/src/github.com/u1and0/grep-server/go.mod | |
| WORKDIR /go/src/github.com/u1and0/grep-server | |
| # For go module using go-pipeline | |
| ENV GO111MODULE=on | |
| RUN apk --update --no-cache add git &&\ | |
| go build -o /go/bin/grep-server | |
| FROM alpine:3.12 as runner | |
| COPY --from=builder /go/bin/grep-server /usr/bin/grep-server | |
| RUN wget https://github.com/phiresky/ripgrep-all/releases/download/v0.9.6/ripgrep_all-v0.9.6-x86_64-unknown-linux-musl.tar.gz | |
| RUN apk --update --no-cache add ripgrep pandoc poppler-utils ffmpeg cargo | |
| ENTRYPOINT ["/usr/bin/grep-server"] | |
| LABEL maintainer="u1and0 <e01.ando60@gmail.com>"\ | |
| description="Running grep-server"\ | |
| version="v0.0.0" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment