Skip to content
This repository has been archived by the owner on Apr 19, 2024. It is now read-only.

Commit

Permalink
Now using 'buf' to generate protobuf files
Browse files Browse the repository at this point in the history
  • Loading branch information
thrawn01 committed Aug 17, 2023
1 parent 4649e4c commit 4fbb48e
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/on-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
run: git fetch --tags

- name: Version consistency check
run: ./check-version.sh
run: ./contrib/check-version.sh

- name: Set up Go
uses: actions/setup-go@v2
Expand Down
9 changes: 9 additions & 0 deletions buf.gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,12 @@ plugins:
- name: go
out: ./
opt: paths=source_relative
- plugin: buf.build/grpc/go:v1.3.0
out: ./
opt:
- paths=source_relative
- require_unimplemented_servers=false
- plugin: buf.build/grpc/python:v1.57.0
out: ./python/gubernator
- plugin: buf.build/protocolbuffers/python
out: ./python/gubernator
8 changes: 8 additions & 0 deletions buf.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Generated by buf. DO NOT EDIT.
version: v1
deps:
- remote: buf.build
owner: googleapis
repository: googleapis
commit: 711e289f6a384c4caeebaff7c6931ade
digest: shake256:e08fb55dad7469f69df00304eed31427d2d1576e9aab31e6bf86642688e04caaf0372f15fe6974cf79432779a635b3ea401ca69c943976dc42749524e4c25d94
14 changes: 14 additions & 0 deletions buf.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
version: v1
deps:
- buf.build/googleapis/googleapis
build:
excludes: []
breaking:
use:
- FILE
lint:
use:
- DEFAULT
rpc_allow_same_request_response: false
rpc_allow_google_protobuf_empty_requests: true
rpc_allow_google_protobuf_empty_responses: true
4 changes: 2 additions & 2 deletions contrib/check-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ else
fi

# Check Helm chart.
HELM_VERSION=$(yq .version charts/gubernator/Chart.yaml)
HELM_VERSION=$(yq .version contrib/charts/gubernator/Chart.yaml)
if [ "$VERSION" != "$HELM_VERSION" ]; then
echo "Helm chart version mismatch: $VERSION <=> $HELM_VERSION" >&2
RETCODE=1
else
echo 'Helm chart version OK'
fi

HELM_APPVERSION=$(yq .appVersion charts/gubernator/Chart.yaml)
HELM_APPVERSION=$(yq .appVersion contrib/charts/gubernator/Chart.yaml)
if [ "$VERSION" != "$HELM_APPVERSION" ]; then
echo "Helm chart appVersion mismatch: $VERSION <=> $HELM_APPVERSION" >&2
RETCODE=1
Expand Down

0 comments on commit 4fbb48e

Please sign in to comment.