Solved Conflict
This commit is contained in:
parent
66fc41cc7f
commit
c0e8b1b8e1
1 changed files with 1 additions and 29 deletions
28
Dockerfile
28
Dockerfile
|
@ -1,5 +1,4 @@
|
|||
|
||||
<<<<<<< HEAD
|
||||
FROM golang:latest
|
||||
RUN mkdir /app
|
||||
RUN mkdir -p /app
|
||||
|
@ -10,30 +9,3 @@ CMD ["/app/main"]
|
|||
ADD . /app
|
||||
RUN go build ./main.go
|
||||
CMD ["./main"]
|
||||
=======
|
||||
# Install git.
|
||||
# Git is required for fetching the dependencies.
|
||||
RUN apk update && apk add --no-cache git
|
||||
|
||||
WORKDIR $GOPATH/src/git.cliffbreak.de/Cliffbreak/tsviewer
|
||||
COPY . .
|
||||
|
||||
# Fetch dependencies.
|
||||
|
||||
# Using go get.
|
||||
RUN go get -d -v
|
||||
|
||||
# Build the binary.
|
||||
RUN GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o /go/bin/main
|
||||
|
||||
############################
|
||||
# STEP 2 build a small image
|
||||
############################
|
||||
FROM scratch
|
||||
|
||||
# Copy our static executable.
|
||||
COPY --from=builder /go/bin/main /go/bin/main
|
||||
|
||||
# Run the hello binary.
|
||||
ENTRYPOINT ["/go/bin/main"]
|
||||
>>>>>>> 5012872895a69040a761a5dec89f72e6c87adbd0
|
||||
|
|
Loading…
Reference in a new issue