https://github.com/janrockdev/grpc-sui
Rust gRPC backend application for interaction with SUI Move smart contract.
https://github.com/janrockdev/grpc-sui
Last synced: over 1 year ago
JSON representation
Rust gRPC backend application for interaction with SUI Move smart contract.
- Host: GitHub
- URL: https://github.com/janrockdev/grpc-sui
- Owner: janrockdev
- License: apache-2.0
- Created: 2024-05-03T22:55:47.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-04T21:43:31.000Z (about 2 years ago)
- Last Synced: 2025-01-24T19:35:29.351Z (over 1 year ago)
- Language: Rust
- Size: 52.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# GRPC-SUI
### Author
Jan Rock (rock@linux.com)
### Version
0.1.0 (5/3/2024)
## Description
Simple Rust gRPC backend application for interation with SUI Move smart contract.
## Install
## Compile
### Smart Contract
From contract folder:
```shell
sui client envs
sui client new-env --alias devnet --rpc https://fullnode.devnet.sui.io:443
sui client active-env
sui client switch --env devnet
sui client active-env
sui client publish --gas-budget 200000000 .
```
## Run
### Server
Environment variables for logging and MongoDB:
```shell
export RUST_LOG=info # or debug
export MONGODB_URL="mongodb+srv://:@cluster0.gsjcz.mongodb.net/?retryWrites=true&w=majority&appName=Cluster0"
export MONGODB_DATABASE=""
```
Run with Cargo:
```shell
cargo run --bin grpc_server
```
### Client
```shell
export RUST_LOG=info # or debug
```
Run with Cargo:
```shell
cargo run --bin grpc_client
```
## Release
```shell
cargo build --release
./target/release/grpc_server
# or
./target/release/grpc_client
```