mirror of
https://github.com/zrepl/zrepl.git
synced 2024-11-22 08:23:50 +01:00
status/interactive: Revert to simple wakeup/reset signalling
Signed-off-by: InsanePrawn <insane.prawny@gmail.com> closes #452
This commit is contained in:
parent
b2c6e51a43
commit
ac4b109872
@ -55,12 +55,8 @@ func (c *Client) signal(job, sig string) error {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *Client) SignalReplication(job string) error {
|
func (c *Client) SignalWakeup(job string) error {
|
||||||
return c.signal(job, "replication")
|
return c.signal(job, "wakeup")
|
||||||
}
|
|
||||||
|
|
||||||
func (c *Client) SignalSnapshot(job string) error {
|
|
||||||
return c.signal(job, "snapshot")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *Client) SignalReset(job string) error {
|
func (c *Client) SignalReset(job string) error {
|
||||||
|
@ -19,8 +19,7 @@ import (
|
|||||||
type Client interface {
|
type Client interface {
|
||||||
Status() (daemon.Status, error)
|
Status() (daemon.Status, error)
|
||||||
StatusRaw() ([]byte, error)
|
StatusRaw() ([]byte, error)
|
||||||
SignalReplication(job string) error
|
SignalWakeup(job string) error
|
||||||
SignalSnapshot(job string) error
|
|
||||||
SignalReset(job string) error
|
SignalReset(job string) error
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -281,8 +281,8 @@ func interactive(c Client, flag statusFlags) error {
|
|||||||
if !ok {
|
if !ok {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
signals := []string{"replication", "snapshot", "reset"}
|
signals := []string{"wakeup", "reset"}
|
||||||
clientFuncs := []func(job string) error{c.SignalReplication, c.SignalSnapshot, c.SignalReset}
|
clientFuncs := []func(job string) error{c.SignalWakeup, c.SignalReset}
|
||||||
sigMod := tview.NewModal()
|
sigMod := tview.NewModal()
|
||||||
sigMod.SetBackgroundColor(tcell.ColorDefault)
|
sigMod.SetBackgroundColor(tcell.ColorDefault)
|
||||||
sigMod.SetBorder(true)
|
sigMod.SetBorder(true)
|
||||||
|
Loading…
Reference in New Issue
Block a user