Initial commit

This commit is contained in:
Jimmy Allen
2020-10-13 21:10:19 +13:00
parent 7164b61dd0
commit bc851eaeb7
8 changed files with 27 additions and 8 deletions

View File

@@ -16,7 +16,7 @@ import (
func main() {
sigs := make(chan os.Signal, 1)
signal.Notify(sigs, syscall.SIGINT, syscall.SIGTERM)
signal.Notify(sigs, syscall.SIGTERM)
var minram, maxram, args, stop string
for _, e := range os.Environ() {
@@ -57,7 +57,7 @@ func main() {
go func() {
sig := <-sigs
if sig == syscall.SIGTERM || sig == syscall.SIGINT {
if sig == syscall.SIGTERM {
fmt.Println("Stopping server")
tty.WriteString(stop + "\n\r")
}