Skip to content

Commit

Permalink
remove ip flag
Browse files Browse the repository at this point in the history
  • Loading branch information
minhd-vu committed Aug 2, 2023
1 parent c6d4b9c commit 44654e4
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions cmd/p2p/sensor/sensor.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import (
"errors"
"fmt"
"io/ioutil"

Check failure on line 8 in cmd/p2p/sensor/sensor.go

View workflow job for this annotation

GitHub Actions / Lint

SA1019: "io/ioutil" has been deprecated since Go 1.19: As of Go 1.16, the same functionality is now provided by package io or package os, and those implementations should be preferred in new code. See the specific function documentation for details. (staticcheck)
"net"
"time"

"net/http"
Expand Down Expand Up @@ -48,7 +47,6 @@ type (
PprofPort uint
KeyFile string
privateKey *ecdsa.PrivateKey
IP net.IP
Port int
RPC string
genesis core.Genesis
Expand Down Expand Up @@ -201,6 +199,7 @@ transactions. If no nodes.json file exists, run echo "{}" >> nodes.json to get s
return fmt.Errorf("unable to parse bootnodes: %w", err)
}
cfg.Bootnodes = bn

ip, err := nat.Parse("any")
if err != nil {
return err
Expand Down Expand Up @@ -290,7 +289,6 @@ increase CPU and memory usage.`)
SensorCmd.PersistentFlags().BoolVar(&inputSensorParams.ShouldRunPprof, "pprof", false, "Whether to run pprof.")
SensorCmd.PersistentFlags().UintVar(&inputSensorParams.PprofPort, "pprof-port", 6060, "The port to run pprof on.")
SensorCmd.PersistentFlags().StringVarP(&inputSensorParams.KeyFile, "key-file", "k", "", "The file of the private key. If no key file is found then a key file will be generated.")
SensorCmd.PersistentFlags().IPVarP(&inputSensorParams.IP, "ip", "i", net.IP{127, 0, 0, 1}, "The sensor's IP address.")
SensorCmd.PersistentFlags().IntVar(&inputSensorParams.Port, "port", 30303, "The sensor's TCP and discovery port.")
SensorCmd.PersistentFlags().StringVar(&inputSensorParams.RPC, "rpc", "https://polygon-rpc.com", "The RPC endpoint.")
SensorCmd.PersistentFlags().StringVar(&inputSensorParams.GenesisFile, "genesis", "genesis.json", "The genesis file.")
Expand Down

0 comments on commit 44654e4

Please sign in to comment.