Minimal URL shortener
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

14 lines
316 B

FROM golang:1.15-alpine3.12 as build
RUN apk add --no-cache git gcc musl-dev sqlite-dev
ADD . /app
WORKDIR /app
RUN go build --tags "libsqlite3 linux"
FROM alpine:3.12
RUN apk add --no-cache sqlite-dev
COPY --from=build /app/goshort /bin/
WORKDIR /app
VOLUME /app/config
VOLUME /app/data
EXPOSE 8080
CMD ["goshort"]