You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
Go to file
codeskyblue 0888d93050
add pushover, it seems blocked in china
8 years ago
Godeps update deps 8 years ago
docs add gif page 8 years ago
pushover add pushover, it seems blocked in china 8 years ago
res today is here 8 years ago
vendor update deps 8 years ago
.fsw.yml try to fix branch, but log still duplicate 8 years ago
.gitignore use gopack to make the build 8 years ago
.gopack.yml add bindata for gopack 8 years ago
.travis.yml fix travis try again 8 years ago
LICENSE Initial commit 9 years ago
README.md today is here 8 years ago
broadcast.go fix write on closed chan error 8 years ago
broadcast_test.go quick fix broadast test 8 years ago
build.sh update self [[DDsupport channel 8 years ago
config.go add config.yml file 8 years ago
deploy.sh today is here 8 years ago
equinox.key.enc add travis equinox.io support 8 years ago
equinox.pub add equinox self update support 8 years ago
fsm.go add pushover, it seems blocked in china 8 years ago
gosuv.go add reload support 8 years ago
res.go update readme 8 years ago
res_bindata.go update readme 8 years ago
res_nobindata.go update readme 8 years ago
utils.go prepare to write new broadcast 8 years ago
web.go fix delete program and reload error 8 years ago

README.md

gosuv

Build Status

Should not use in production now (current is in alpha)

Process management writtern by golang, inspired by python-supervisor

Features

  • Realtime log view

  • Web control page

  • HTTP Basic auth

  • Github webhook

  • Single log page, include search support

  • 中文文档

Requirements

Go version at least 1.6+

Installation

Standalone binary can be download from one of the following addresses

Branch Source Address
stable equinox https://dl.equinox.io/shengxiang/gosuv/stable
stable github https://github.com/codeskyblue/gosuv/releases/latest
dev equinox https://dl.equinox.io/shengxiang/gosuv/dev

Or if you have go enviroment, you can also build from source.

go get -d github.com/codeskyblue/gosuv
cd $GOPATH/src/github.com/codeskyblue/gosuv
go build

If you want to build a standalone binary, run the following command.

go get github.com/elazarl/go-bindata-assetfs/...
go-bindata-assetfs -tags bindata res/...
go build -tags bindata

Usage

Start server in the background

gosuv start-server

Show server status

$ gosuv status
Server is running

Open web http://localhost:11313 to see the manager page.

gosuv web

Configuration

Default config file stored in directory $HOME/.gosuv/

  • file programs.yml contains all program settings.
  • file config.yml contains server config

File config.yml can be generated by gosuv conftest

Example config.yaml

server:
  httpauth:
    enabled: false
    username: uu
    password: pp
  addr: :11313
client:
  server_url: http://localhost:11313

Logs can be found in $HOME/.gosuv/log/

Design

HTTP is follow the RESTFul guide.

Get or Update program

<GET|PUT> /api/programs/:name

Add new program

POST /api/programs

Del program

DELETE /api/programs/:name

State

Only 4 states. ref

states

Notification (todo)

Configuration example

notifications:
  on:
    fatal: true
  pushover:
    api_key: [token]
    users:
    - [user1]
    - [user2]

Pushover

https://pushover.net/api

Plugin Design (todo)

Current plugins:

All command plugin will store in $HOME/.gosuv/cmdplugin, gosuv will treat this plugin as a subcommand.

for example:

$HOME/.gosuv/cmdplugin/ --.
	|- showpid/
		|- run

There is a directory showpid

When run gosuv showpid, file run will be called.

Use libs

LICENSE

MIT