mirror of
https://github.com/sonr-io/sonr.git
synced 2026-08-02 17:31:39 +00:00
23 lines
417 B
Go
23 lines
417 B
Go
package front
|
|||
|
|
|
||
|
|
import (
|
||
|
|
"log"
|
||
|
|
"net/http"
|
||
|
|
|
||
|
|
"github.com/labstack/echo/v4"
|
||
|
|
"github.com/spf13/cobra"
|
||
|
|
)
|
||
|
|
|
||
|
|
func NewServeFrontendCmd() *cobra.Command {
|
||
|
|
return &cobra.Command{
|
||
|
|
Use: "serve-web",
|
||
|
|
Short: "TUI for managing the local Sonr validator node",
|
||
|
|
Run: func(cmd *cobra.Command, args []string) {
|
||
|
|
e := echo.New()
|
||
|
|
if err := e.Start(":42069"); err != http.ErrServerClosed {
|
||
|
|
log.Fatal(err)
|
||
|
|
}
|
||
|
|
},
|
||
|
|
}
|
||
|
|
}
|