Skip to content

Commit

Permalink
Build lightstep image based on alpine
Browse files Browse the repository at this point in the history
Signed-off-by: Mikkel Oscar Lyderik Larsen <mikkel.larsen@zalando.de>
  • Loading branch information
mikkeloscar committed Aug 31, 2018
1 parent 5d7ae30 commit 0582aa4
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 4 deletions.
23 changes: 20 additions & 3 deletions packaging/Dockerfile.lightstep
Original file line number Diff line number Diff line change
@@ -1,7 +1,24 @@
FROM registry.opensource.zalan.do/stups/ubuntu:latest
# builder image
FROM golang:alpine as builder

RUN apk add -U git && \
go get github.com/Masterminds/glide
COPY . .
RUN go get -d github.com/skipper-plugins/opentracing && \
cd /go/src/github.com/skipper-plugins/opentracing && \
glide install --strip-vendor && \
GOOS=linux GOARCH=amd64 CGO_ENABLED=1 make

# final image
FROM alpine
MAINTAINER Skipper Maintainers <team-pathfinder@zalando.de>
RUN apk --no-cache add ca-certificates && update-ca-certificates
RUN mkdir -p /usr/bin
ADD skipper eskip /usr/bin/
EXPOSE 9090 9911
ENV PATH $PATH:/usr/bin
RUN mkdir -p /plugins
ADD build/tracing_lightstep.so /plugins/
COPY --from=builder /go/src/github.com/skipper-plugins/opentracing/build/tracing_lightstep.so /plugins/

EXPOSE 9090 9911

ENTRYPOINT ["/usr/bin/skipper", "-plugindir", "/plugins"]
2 changes: 1 addition & 1 deletion packaging/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ plugins:
GOOS=linux GOARCH=amd64 CGO_ENABLED=1 make ;\
cp build/*.so $$CUR/build/

docker-lightstep-build: skipper eskip plugins
docker-lightstep-build: skipper eskip
docker build -t $(LIGHTSTEP_IMAGE) -f Dockerfile.lightstep .

docker-lightstep-push:
Expand Down

0 comments on commit 0582aa4

Please sign in to comment.