Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(prototool): Add grpc-gateway protoc plugin #66

Merged
merged 1 commit into from
Mar 27, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 11 additions & 3 deletions prototool/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
FROM golang:1.11.0-alpine3.8 AS build

ENV PROTOTOOL_VERSION=1.3.0
ENV PROTOTOOL_VERSION=1.4.0
ENV PROTOC_VERSION=3.6.1
ENV PROTOC_GEN_GO_VERSION=1.2.0
ENV PROTOC_GEN_GO_VERSION=1.3.1
ENV PROTOC_GEN_GRPC_GATEWAY_VERSION=1.8.5

RUN apk add --no-cache curl git libc6-compat

Expand All @@ -20,6 +21,11 @@ RUN go get github.com/golang/protobuf/... && \
git checkout -b v$PROTOC_GEN_GO_VERSION && \
go install ./protoc-gen-go

RUN go get github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway && \
cd /go/src/github.com/grpc-ecosystem/grpc-gateway && \
git checkout -b v$PROTOC_GEN_GRPC_GATEWAY_VERSION && \
go install ./protoc-gen-grpc-gateway

FROM alpine:3.8

LABEL vendor="Jobteaser" \
Expand All @@ -35,11 +41,13 @@ RUN apk add --no-cache libc6-compat git make ruby su-exec && \

COPY --from=build /usr/local/bin/prototool /usr/local/bin/prototool
COPY --from=build /go/bin/protoc-gen-go /usr/local/bin/protoc-gen-go
COPY --from=build /go/bin/protoc-gen-grpc-gateway /usr/local/bin/protoc-gen-grpc-gateway

ENV PATH /usr/local/go/bin:$PATH

RUN chmod +x /usr/local/bin/prototool && \
chmod +x /usr/local/bin/protoc-gen-go
chmod +x /usr/local/bin/protoc-gen-go && \
chmod +x /usr/local/bin/protoc-gen-grpc-gateway

COPY entrypoint.sh /usr/local/bin/entrypoint.sh
RUN chmod +x /usr/local/bin/entrypoint.sh
Expand Down