mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-12 06:53:46 +00:00
cmd/swarm: added websocket capability (for pss)
This commit is contained in:
parent
7ab9a617eb
commit
0628dbaab9
1 changed files with 11 additions and 0 deletions
|
|
@ -267,6 +267,14 @@ Cleans database of corrupted entries.
|
||||||
// pss flags
|
// pss flags
|
||||||
PssEnabledFlag,
|
PssEnabledFlag,
|
||||||
}
|
}
|
||||||
|
rpcFlags := []cli.Flag{
|
||||||
|
utils.WSEnabledFlag,
|
||||||
|
utils.WSListenAddrFlag,
|
||||||
|
utils.WSPortFlag,
|
||||||
|
utils.WSApiFlag,
|
||||||
|
utils.WSAllowedOriginsFlag,
|
||||||
|
}
|
||||||
|
app.Flags = append(app.Flags, rpcFlags...)
|
||||||
app.Flags = append(app.Flags, debug.Flags...)
|
app.Flags = append(app.Flags, debug.Flags...)
|
||||||
app.Before = func(ctx *cli.Context) error {
|
app.Before = func(ctx *cli.Context) error {
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
runtime.GOMAXPROCS(runtime.NumCPU())
|
||||||
|
|
@ -301,6 +309,9 @@ func version(ctx *cli.Context) error {
|
||||||
|
|
||||||
func bzzd(ctx *cli.Context) error {
|
func bzzd(ctx *cli.Context) error {
|
||||||
cfg := defaultNodeConfig
|
cfg := defaultNodeConfig
|
||||||
|
if ctx.GlobalBool(PssEnabledFlag.Name) && ctx.GlobalBool(utils.WSEnabledFlag.Name) {
|
||||||
|
cfg.WSModules = append(cfg.WSModules, "pss")
|
||||||
|
}
|
||||||
utils.SetNodeConfig(ctx, &cfg)
|
utils.SetNodeConfig(ctx, &cfg)
|
||||||
stack, err := node.New(&cfg)
|
stack, err := node.New(&cfg)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue