fix: typo fixes and dione image upload
This commit is contained in:
parent
a1db429717
commit
9bb4f1cfa3
BIN
assets/img/dione.jpg
Normal file
BIN
assets/img/dione.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 248 KiB |
@ -11,12 +11,12 @@ type Config struct {
|
|||||||
BootstrapNodeMultiaddr string `mapstructure:"bootstrap_node_multiaddr"`
|
BootstrapNodeMultiaddr string `mapstructure:"bootstrap_node_multiaddr"`
|
||||||
Rendezvous string `mapstructure:"rendezvous"`
|
Rendezvous string `mapstructure:"rendezvous"`
|
||||||
SessionKey string `mapstructure:"session_key"`
|
SessionKey string `mapstructure:"session_key"`
|
||||||
Etherium EtheriumConfig `mapstructure:"etherium"`
|
Ethereum EthereumConfig `mapstructure:"ethereum"`
|
||||||
Filecoin FilecoinConfig `mapstructure:"filecoin"`
|
Filecoin FilecoinConfig `mapstructure:"filecoin"`
|
||||||
PubSub PubSubConfig `mapstructure:"pubSub"`
|
PubSub PubSubConfig `mapstructure:"pubSub"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type EtheriumConfig struct {
|
type EthereumConfig struct {
|
||||||
GatewayAddress string `mapstructure:"gateway_address"`
|
GatewayAddress string `mapstructure:"gateway_address"`
|
||||||
PrivateKey string `mapstructure:"private_key"`
|
PrivateKey string `mapstructure:"private_key"`
|
||||||
OracleEmitterContractAddress string `mapstructure:"oracle_emitter_contract_address"`
|
OracleEmitterContractAddress string `mapstructure:"oracle_emitter_contract_address"`
|
||||||
@ -40,7 +40,7 @@ func NewConfig(configPath string) (*Config, error) {
|
|||||||
Bootstrap: false,
|
Bootstrap: false,
|
||||||
BootstrapNodeMultiaddr: "/ip4/127.0.0.1/tcp/0",
|
BootstrapNodeMultiaddr: "/ip4/127.0.0.1/tcp/0",
|
||||||
Rendezvous: "filecoin-p2p-oracle",
|
Rendezvous: "filecoin-p2p-oracle",
|
||||||
Etherium: EtheriumConfig{
|
Ethereum: EthereumConfig{
|
||||||
PrivateKey: "",
|
PrivateKey: "",
|
||||||
},
|
},
|
||||||
SessionKey: "go",
|
SessionKey: "go",
|
||||||
|
@ -13,7 +13,7 @@ type PubSubConfig struct {
|
|||||||
ProtocolID string `toml:"protocolID"`
|
ProtocolID string `toml:"protocolID"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type EtheriumConfig struct {
|
type EthereumConfig struct {
|
||||||
PrivateKey string `toml:"privateKey"`
|
PrivateKey string `toml:"privateKey"`
|
||||||
GatewayAddress string `toml:"gatewayAddress"`
|
GatewayAddress string `toml:"gatewayAddress"`
|
||||||
}
|
}
|
||||||
|
12
node/node.go
12
node/node.go
@ -64,19 +64,19 @@ func (n *Node) setupNode(ctx context.Context, prvKey crypto.PrivKey) {
|
|||||||
}
|
}
|
||||||
n.Host = host
|
n.Host = host
|
||||||
n.bootstrapLibp2pHost(context.TODO())
|
n.bootstrapLibp2pHost(context.TODO())
|
||||||
n.setupEtheriumClient()
|
n.setupEthereumClient()
|
||||||
n.setupFilecoinClient()
|
n.setupFilecoinClient()
|
||||||
//n.startPubSub(ctx, host)
|
//n.startPubSub(ctx, host)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (n *Node) setupEtheriumClient() error {
|
func (n *Node) setupEthereumClient() error {
|
||||||
ethereum := rpcclient.NewEthereumClient()
|
ethereum := rpcclient.NewEthereumClient()
|
||||||
n.Ethereum = ethereum
|
n.Ethereum = ethereum
|
||||||
return ethereum.Initialize(context.Background(),
|
return ethereum.Initialize(context.Background(),
|
||||||
n.Config.Etherium.GatewayAddress,
|
n.Config.Ethereum.GatewayAddress,
|
||||||
n.Config.Etherium.PrivateKey,
|
n.Config.Ethereum.PrivateKey,
|
||||||
n.Config.Etherium.OracleEmitterContractAddress,
|
n.Config.Ethereum.OracleEmitterContractAddress,
|
||||||
n.Config.Etherium.AggregatorContractAddress,
|
n.Config.Ethereum.AggregatorContractAddress,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user