Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove avalanchego dependency, update key reading/signing #31

Merged
merged 3 commits into from
Sep 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions camino-messenger-bot-distributor.yaml.example
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ developer_mode: true

### Matrix

# Private key to be used to login to Matrix Server
matrix_key: PrivateKey-YOUR_PRIVATE_KEY
# Private key to be used to login to Matrix Server. This should be in hex format
# without the 0x prefix.
matrix_key: YOUR_PRIVATE_KEY_HEX

# Hostname of the Matrix Server
matrix_host: matrix.camino.network
Expand Down Expand Up @@ -54,9 +55,10 @@ supported_request_types:

### C-Chain (EVM)

# Used for signing transactions on the c-chain, can be same as the matrix_key.
# This address needs to have some funds to pay for transaction fees on the C-Chain.
evm_private_key: PrivateKey-YOUR_PRIVATE_KEY
# Used for signing transactions on the c-chain, can be same as the matrix_key. This
# address needs to have some funds to pay for transaction fees on the C-Chain. This
# should be in hex format without the 0x prefix.
evm_private_key: YOUR_PRIVATE_KEY_HEX

# C-Chain RPC URL
rpc_url: wss://columbus.camino.network/ext/bc/C/ws
Expand Down
12 changes: 7 additions & 5 deletions camino-messenger-bot-supplier.yaml.example
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ developer_mode: true

### Matrix

# Private key to be used to login to Matrix Server
matrix_key: PrivateKey-YOUR_PRIVATE_KEY
# Private key to be used to login to Matrix Server. This should be in hex format
# without the 0x prefix.
matrix_key: YOUR_PRIVATE_KEY_HEX

# Hostname of the Matrix Server
matrix_host: matrix.camino.network
Expand Down Expand Up @@ -66,9 +67,10 @@ supported_request_types:

### C-Chain (EVM)

# Used for signing transactions on the c-chain, can be same as the matrix_key.
# This address needs to have some funds to pay for transaction fees on the C-Chain.
evm_private_key: PrivateKey-YOUR_PRIVATE_KEY
# Used for signing transactions on the c-chain, can be same as the matrix_key. This
# address needs to have some funds to pay for transaction fees on the C-Chain. This
# should be in hex format without the 0x prefix.
evm_private_key: YOUR_PRIVATE_KEY_HEX

# C-Chain RPC URL
rpc_url: wss://columbus.camino.network/ext/bc/C/ws
Expand Down
8 changes: 4 additions & 4 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ services:
dockerfile: Dockerfile
environment:
CMB_DEVELOPER_MODE: "true"
CMB_MATRIX_KEY: "PrivateKey-THE_REST_OF_THE_KEY"
CMB_MATRIX_KEY: "PRIVATE_KEY_HEX"
CMB_MATRIX_HOST: "matrix.camino.network"
CMB_MATRIX_STORE: "supplier-matrix.db"
CMB_RPC_SERVER_PORT: "9090"
Expand All @@ -20,7 +20,7 @@ services:
CMB_RPC_URL: "https://columbus.camino.network/ext/bc/C/rpc"
CMB_BOOKING_TOKEN_ABI_FILE: abi/BookingTokenV0.abi
CMB_SUPPLIER_NAME: SUPPLIER_NAME
CMB_EVM_PRIVATE_KEY: "PrivateKey-THE_REST_OF_THE_KEY"
CMB_EVM_PRIVATE_KEY: "PRIVATE_KEY_HEX"
CMB_BUYABLE_UNTIL_DEFAULT: "600"
ports:
- "9090:9090"
Expand All @@ -31,7 +31,7 @@ services:
dockerfile: Dockerfile
environment:
CMB_DEVELOPER_MODE: "true"
CMB_MATRIX_KEY: "PrivateKey-THE_REST_OF_THE_KEY"
CMB_MATRIX_KEY: "PRIVATE_KEY_HEX"
CMB_MATRIX_HOST: "matrix.camino.network"
CMB_MATRIX_STORE: "distributor-matrix.db"
CMB_RPC_SERVER_PORT: "9090"
Expand All @@ -40,7 +40,7 @@ services:
CMB_SUPPORTED_REQUEST_TYPES: "GetNetworkFeeRequest,GetPartnerConfigurationRequest,PingRequest"
CMB_RPC_URL: "https://columbus.camino.network/ext/bc/C/rpc"
CMB_BOOKING_TOKEN_ABI_FILE: "abi/BookingTokenV0.abi"
CMB_EVM_PRIVATE_KEY: "PrivateKey-THE_REST_OF_THE_KEY"
CMB_EVM_PRIVATE_KEY: "PRIVATE_KEY_HEX"
ports:
- "9092:9090"
provider-plugin:
Expand Down
8 changes: 5 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ go 1.23.1
require (
buf.build/gen/go/chain4travel/camino-messenger-protocol/grpc/go v1.5.1-20240902074016-adcea0949c54.1
buf.build/gen/go/chain4travel/camino-messenger-protocol/protocolbuffers/go v1.34.2-20240902074016-adcea0949c54.2
github.com/ava-labs/avalanchego v1.10.18
github.com/chain4travel/camino-messenger-contracts/go/contracts v0.0.0-20240918114804-fbc75cbe60fc
github.com/ethereum/go-ethereum v1.14.8
github.com/google/uuid v1.6.0
Expand All @@ -26,6 +25,7 @@ require (
)

require (
github.com/DataDog/zstd v1.5.2 // indirect
github.com/Microsoft/go-winio v0.6.2 // indirect
github.com/bits-and-blooms/bitset v1.10.0 // indirect
github.com/btcsuite/btcd/btcec/v2 v2.3.4 // indirect
Expand All @@ -37,24 +37,25 @@ require (
github.com/deckarep/golang-set/v2 v2.6.0 // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect
github.com/ethereum/c-kzg-4844 v1.0.0 // indirect
github.com/gballet/go-libpcsclite v0.0.0-20191108122812-4678299bea08 // indirect
github.com/go-logr/logr v1.3.0 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-ole/go-ole v1.3.0 // indirect
github.com/google/renameio/v2 v2.0.0 // indirect
github.com/gorilla/websocket v1.5.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.15.2 // indirect
github.com/holiman/uint256 v1.3.1 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/mmcloughlin/addchain v0.4.0 // indirect
github.com/mr-tron/base58 v1.2.0 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
github.com/prometheus/client_golang v1.16.0 // indirect
github.com/rivo/uniseg v0.4.4 // indirect
github.com/rogpeppe/go-internal v1.10.0 // indirect
github.com/rs/zerolog v1.31.0 // indirect
github.com/shirou/gopsutil v3.21.11+incompatible // indirect
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/supranational/blst v0.3.11 // indirect
github.com/syndtr/goleveldb v1.0.1-0.20220614013038-64ee5596c38a // indirect
github.com/tidwall/gjson v1.17.0 // indirect
github.com/tidwall/match v1.1.1 // indirect
github.com/tidwall/pretty v1.2.0 // indirect
Expand All @@ -65,6 +66,7 @@ require (
go.mau.fi/util v0.3.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.11.2 // indirect
go.opentelemetry.io/proto/otlp v0.19.0 // indirect
go.uber.org/goleak v1.2.1 // indirect
golang.org/x/crypto v0.24.0 // indirect
golang.org/x/text v0.16.0 // indirect
google.golang.org/genproto v0.0.0-20240123012728-ef4313101c80 // indirect
Expand Down
Loading