first take at "daemon stop" command

Fixes #1827

TODO: plumb the daemon-stopping into lotus-storage-miner, too
This commit is contained in:
laser
2020-06-02 12:29:58 -07:00
parent 5e727819ad
commit 38d714a28a
8 changed files with 49 additions and 9 deletions
+6
View File
@@ -47,6 +47,8 @@ type CommonStruct struct {
LogList func(context.Context) ([]string, error) `perm:"write"`
LogSetLevel func(context.Context, string, string) error `perm:"write"`
Shutdown func(context.Context) error `perm:"admin"`
}
}
@@ -293,6 +295,10 @@ func (c *CommonStruct) LogSetLevel(ctx context.Context, group, level string) err
return c.Internal.LogSetLevel(ctx, group, level)
}
func (c *CommonStruct) Shutdown(ctx context.Context) error {
return c.Internal.Shutdown(ctx)
}
// FullNodeStruct
func (c *FullNodeStruct) ClientListImports(ctx context.Context) ([]api.Import, error) {