Format
This commit is contained in:
parent
23230fad68
commit
c234b11cc2
|
@ -86,15 +86,14 @@ func main() {
|
||||||
|
|
||||||
// Graceful Shutdown
|
// Graceful Shutdown
|
||||||
c := make(chan os.Signal, 1)
|
c := make(chan os.Signal, 1)
|
||||||
signal.Notify(c, os.Interrupt, syscall.SIGTERM)
|
signal.Notify(c, os.Interrupt, syscall.SIGTERM)
|
||||||
go func(){
|
go func() {
|
||||||
<-c
|
<-c
|
||||||
acn.Close()
|
acn.Close()
|
||||||
server.Close()
|
server.Close()
|
||||||
os.Exit(1)
|
os.Exit(1)
|
||||||
}()
|
}()
|
||||||
|
|
||||||
|
|
||||||
server.Run(acn)
|
server.Run(acn)
|
||||||
for {
|
for {
|
||||||
time.Sleep(time.Second)
|
time.Sleep(time.Second)
|
||||||
|
|
|
@ -20,20 +20,20 @@ type Reporting struct {
|
||||||
|
|
||||||
// Config is a struct for storing basic server configuration
|
// Config is a struct for storing basic server configuration
|
||||||
type Config struct {
|
type Config struct {
|
||||||
ConfigDir string `json:"-"`
|
ConfigDir string `json:"-"`
|
||||||
FilePath string `json:"-"`
|
FilePath string `json:"-"`
|
||||||
MaxBufferLines int `json:"maxBufferLines"`
|
MaxBufferLines int `json:"maxBufferLines"`
|
||||||
|
|
||||||
PublicKey ed25519.PublicKey `json:"publicKey"`
|
PublicKey ed25519.PublicKey `json:"publicKey"`
|
||||||
PrivateKey ed25519.PrivateKey `json:"privateKey"`
|
PrivateKey ed25519.PrivateKey `json:"privateKey"`
|
||||||
|
|
||||||
TokenServerPublicKey ed25519.PublicKey `json:"tokenServerPublicKey"`
|
TokenServerPublicKey ed25519.PublicKey `json:"tokenServerPublicKey"`
|
||||||
TokenServerPrivateKey ed25519.PrivateKey `json:"tokenServerPrivateKey"`
|
TokenServerPrivateKey ed25519.PrivateKey `json:"tokenServerPrivateKey"`
|
||||||
|
|
||||||
TokenServiceK ristretto255.Scalar `json:"tokenServiceK"`
|
TokenServiceK ristretto255.Scalar `json:"tokenServiceK"`
|
||||||
|
|
||||||
ServerReporting Reporting `json:"serverReporting"`
|
ServerReporting Reporting `json:"serverReporting"`
|
||||||
AutoStart bool `json:"autostart"`
|
AutoStart bool `json:"autostart"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Identity returns an encapsulation of the servers keys
|
// Identity returns an encapsulation of the servers keys
|
||||||
|
|
Loading…
Reference in New Issue