Skip to content

Commit

Permalink
add connect-go@v1.3.1 and grpc-node@v1.12.0 (#247)
Browse files Browse the repository at this point in the history
New plugin versions found. Please review.

Co-authored-by: pkwarren <pkwarren@users.noreply.github.com>
  • Loading branch information
app-token-plugins[bot] and pkwarren authored Dec 1, 2022
1 parent 5de9b98 commit d6393a5
Show file tree
Hide file tree
Showing 12 changed files with 1,076 additions and 0 deletions.
2 changes: 2 additions & 0 deletions plugins/bufbuild/connect-go/v1.3.1/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
*
!Dockerfile
11 changes: 11 additions & 0 deletions plugins/bufbuild/connect-go/v1.3.1/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# syntax=docker/dockerfile:1.4
FROM golang:1.19.3-bullseye AS build
RUN --mount=type=cache,target=/go/pkg/mod \
CGO_ENABLED=0 \
go install -ldflags="-s -w" -trimpath github.com/bufbuild/connect-go/cmd/protoc-gen-connect-go@v1.3.1

FROM scratch
COPY --from=build --link --chown=root:root /etc/passwd /etc/passwd
COPY --from=build --link /go/bin/protoc-gen-connect-go /
USER nobody
ENTRYPOINT [ "/protoc-gen-connect-go" ]
19 changes: 19 additions & 0 deletions plugins/bufbuild/connect-go/v1.3.1/buf.plugin.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
version: v1
name: buf.build/bufbuild/connect-go
plugin_version: v1.3.1
source_url: https://github.com/bufbuild/connect-go
description: Generates client and server stubs for connect-go. Compatible with the gRPC, gRPC-Web, and Connect RPC protocols.
deps:
- plugin: buf.build/protocolbuffers/go:v1.28.1
output_languages:
- go
registry:
go:
min_version: "1.18"
deps:
- module: github.com/bufbuild/connect-go
version: v1.3.1
opts:
- paths=source_relative
spdx_license_id: Apache-2.0
license_url: https://github.com/bufbuild/connect-go/blob/v1.3.1/LICENSE
3 changes: 3 additions & 0 deletions plugins/grpc/node/v1.12.0/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
*
!Dockerfile
!package*.json
28 changes: 28 additions & 0 deletions plugins/grpc/node/v1.12.0/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# syntax=docker/dockerfile:1.4
FROM node:18.12.1-bullseye AS build

ARG TARGETARCH

WORKDIR /build
COPY --link package* .
RUN /bin/bash <<'EOF'
set -e
# https://github.com/grpc/grpc-node/issues/1405#issuecomment-1195903603 - linux/arm64 binaries not available
if [ "${TARGETARCH}" = "arm64" ]; then
apt update
apt install -y git build-essential file jq cmake
git clone --recursive --depth 1 --branch grpc-tools@1.12.0 https://github.com/grpc/grpc-node.git
cd grpc-node/packages/grpc-tools
sed -i -e '# -m64##g' linux_64bit.toolchain.cmake
cmake linux_64bit.toolchain.cmake . && cmake --build . --target clean && cmake --build . -- -j 12
cp grpc_node_plugin /build
else
npm ci
cp /build/node_modules/grpc-tools/bin/grpc_node_plugin /build
fi
EOF

FROM gcr.io/distroless/cc-debian11
COPY --from=build --link --chmod=0755 --chown=root:root /build/grpc_node_plugin .
USER nobody
ENTRYPOINT [ "/grpc_node_plugin" ]
21 changes: 21 additions & 0 deletions plugins/grpc/node/v1.12.0/buf.plugin.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
version: v1
name: buf.build/grpc/node
plugin_version: v1.12.0
source_url: https://github.com/grpc/grpc-node
description: Generates Node client and server stubs for the gRPC framework.
deps:
- plugin: buf.build/protocolbuffers/js:v3.21.2
output_languages:
- javascript
registry:
npm:
import_style: commonjs
deps:
- package: '@grpc/grpc-js'
version: '^1.7.3'
- package: 'google-protobuf'
version: '^3.21.2'
opts:
- grpc_js
spdx_license_id: Apache-2.0
license_url: 'https://github.com/grpc/grpc-node/blob/grpc-tools%401.12.0/LICENSE'
Loading

0 comments on commit d6393a5

Please sign in to comment.