Skip to content

Commit adc31a8

Browse files
Update bufbuild/es and grpc plugins (#2073)
1 parent 3f1ef32 commit adc31a8

File tree

38 files changed

+946
-0
lines changed

38 files changed

+946
-0
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
*
2+
!Dockerfile
3+
!package*.json
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# syntax=docker/dockerfile:1.19
2+
FROM node:24.10.0-bookworm AS build
3+
WORKDIR /app
4+
COPY --link package*.json .
5+
RUN npm ci \
6+
&& find node_modules/typescript ! -name 'typescript.js' ! -name 'package.json' -type f -exec rm -f {} + \
7+
&& find node_modules/typescript -depth -type d -empty -delete \
8+
&& ./node_modules/.bin/esbuild ./node_modules/.bin/protoc-gen-es --bundle --external:typescript --platform=node --outfile=protoc-gen-es.js
9+
10+
FROM gcr.io/distroless/nodejs24-debian12:latest@sha256:acc00c9fd71a24aea69e53c01cee55f54383182af2557b9ec77432bbb36ec911 AS node
11+
12+
FROM gcr.io/distroless/cc-debian12:latest@sha256:0000f9dc0290f8eaf0ecceafbc35e803649087ea7879570fbc78372df7ac649b AS base
13+
14+
FROM scratch
15+
COPY --link --from=base / /
16+
COPY --link --from=node --chmod=0755 /nodejs/bin/node /nodejs/bin/node
17+
COPY --link --from=build --chmod=0755 /app/protoc-gen-es.js /app/protoc-gen-es.js
18+
COPY --link --from=build /app/node_modules/typescript /app/node_modules/typescript
19+
USER nobody
20+
ENTRYPOINT ["/nodejs/bin/node"]
21+
CMD [ "/app/protoc-gen-es.js" ]
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
version: v1
2+
name: buf.build/bufbuild/es
3+
plugin_version: v2.10.0
4+
source_url: https://github.com/bufbuild/protobuf-es
5+
integration_guide_url: https://github.com/bufbuild/protobuf-es#quickstart
6+
description: Types for TypeScript/JavaScript for use in web browsers and Node.js. Generates message and enum types, but also services for use with Connect v2.
7+
output_languages:
8+
- javascript
9+
- typescript
10+
registry:
11+
opts:
12+
- import_extension=js
13+
npm:
14+
import_style: module
15+
rewrite_import_path_suffix: pb.js
16+
deps:
17+
- package: '@bufbuild/protobuf'
18+
version: ^2.10.0
19+
spdx_license_id: Apache-2.0
20+
license_url: https://github.com/bufbuild/protobuf-es/blob/v2.10.0/LICENSE

0 commit comments

Comments
 (0)