add common unit test

This commit is contained in:
Jay
2020-01-14 15:00:01 +00:00
parent 9b9edf08d8
commit ed4ee637ab
4 changed files with 55 additions and 4 deletions
+12
View File
@@ -0,0 +1,12 @@
FROM golang:1-alpine as builder
WORKDIR /data
COPY . .
RUN apk add --no-cache build-base make && \
make test && \
make
FROM alpine:latest
WORKDIR /data
COPY ./config/config.yml .
COPY --from=builder /data/tcp-proxy /usr/bin/tcp-proxy
CMD ["/usr/bin/tcp-proxy"]