update modules

This commit is contained in:
Adrien Marquès 2020-03-08 16:34:00 +01:00
parent 74537bc0a8
commit a2bd3a85f5
Signed by: xdrm-brackets
GPG Key ID: D75243CA236D825E
3 changed files with 7 additions and 6 deletions

View File

@ -3,15 +3,16 @@ FROM golang:alpine as builder
ENV GO111MODULE=on ENV GO111MODULE=on
RUN apk add git RUN apk add git
ADD . /app ADD . /app
WORKDIR /app WORKDIR /app
RUN go get -d ./... RUN go mod download
RUN CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build -o tiny-url RUN CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build -ldflags="-s -w" -o binary
FROM alpine:latest as production FROM alpine:latest as production
RUN mkdir /app RUN mkdir /app
COPY --from=builder /app/tiny-url /app COPY --from=builder /app/binary /app
COPY --from=builder /app/api.json /app COPY --from=builder /app/api.json /app
WORKDIR /app WORKDIR /app
EXPOSE 4242/tcp EXPOSE 4242/tcp
CMD "/app/tiny-url" CMD "/app/binary"

2
go.mod
View File

@ -1,5 +1,5 @@
module git.xdrm.io/go/tiny-url-ex module git.xdrm.io/go/tiny-url-ex
go 1.12 go 1.14
require git.xdrm.io/go/aicra v0.2.0 require git.xdrm.io/go/aicra v0.2.0

2
go.sum
View File

@ -1,2 +1,2 @@
git.xdrm.io/go/aicra v0.2.0 h1:Hn5g4qFikAjC7l4uaWD41eiJhYLlAUsjnAx9H0r6WNQ= git.xdrm.io/go/aicra v0.2.0 h1:CHXkNA13xH4cnZD/on0i+lcwaAEVnI2QFeFfK9mVpcM=
git.xdrm.io/go/aicra v0.2.0/go.mod h1:ulAzCdKqUN5X4eWQSER70QXSYteSXtybAqupcUuYPdw= git.xdrm.io/go/aicra v0.2.0/go.mod h1:ulAzCdKqUN5X4eWQSER70QXSYteSXtybAqupcUuYPdw=