mirror of
https://github.com/0ceanSlim/grain.git
synced 2024-10-29 17:16:31 +00:00
move config watcher to config package
This commit is contained in:
parent
4e218c292a
commit
82a45048f5
@ -1,4 +1,4 @@
|
||||
package utils
|
||||
package config
|
||||
|
||||
import (
|
||||
"fmt"
|
2
main.go
2
main.go
@ -25,7 +25,7 @@ func main() {
|
||||
utils.EnsureFileExists("relay_metadata.json", "app/static/examples/relay_metadata.example.json")
|
||||
|
||||
restartChan := make(chan struct{})
|
||||
go utils.WatchConfigFile("config.yml", restartChan) // Critical goroutine
|
||||
go config.WatchConfigFile("config.yml", restartChan) // Critical goroutine
|
||||
|
||||
signalChan := make(chan os.Signal, 1)
|
||||
signal.Notify(signalChan, syscall.SIGINT, syscall.SIGTERM)
|
||||
|
Loading…
Reference in New Issue
Block a user