-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The rust code is generated using the [`neoeinstein/protoc-gen-prost`] (https://github.com/neoeinstein/protoc-gen-prost), which leverages the `prost` crate for protobuf and `tonic` crate for client/server. The rust crates used are: pbjson and pbjson-types: 0.7.0 prost: 0.13.1 tonic: 0.12.0 Currently, the generated code does not use `protoc-prost-serde` to support serde, since serde and json deserialization is not necessary for the basic use case. Signed-off-by: Campbell He <[email protected]>
- Loading branch information
1 parent
c143633
commit f50fef9
Showing
15 changed files
with
4,874 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,3 +7,6 @@ build | |
dist | ||
*.egg-info | ||
.eggs | ||
|
||
# rust | ||
target/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ LABEL description="Dockerfile used for CI testing of p4lang/p4runtime" | |
ARG DEBIAN_FRONTEND=noninteractive | ||
|
||
RUN apt-get update && \ | ||
apt-get install -y --no-install-recommends software-properties-common git curl | ||
apt-get install -y --no-install-recommends software-properties-common git curl build-essential | ||
|
||
ARG GO_VERSION=1.20.5 | ||
|
||
|
@@ -26,5 +26,11 @@ ENV PATH="${PATH}:/usr/local/go/bin:/root/go/bin" | |
RUN go install google.golang.org/protobuf/cmd/[email protected] | ||
RUN go install google.golang.org/grpc/cmd/[email protected] | ||
|
||
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain stable --profile minimal; \ | ||
. $HOME/.cargo/env; \ | ||
cargo install protoc-gen-prost protoc-gen-prost-crate protoc-gen-prost-serde protoc-gen-tonic | ||
|
||
ENV PATH="${PATH}:/root/.cargo/bin" | ||
|
||
COPY . /p4runtime/ | ||
WORKDIR /p4runtime/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.