all: Remove need to restart syncthing (#6883)
This commit is contained in:
@@ -12,6 +12,7 @@ import (
|
||||
"crypto/tls"
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
@@ -448,3 +449,15 @@ func (c *contextClient) Post(ctx context.Context, url, ctype string, data io.Rea
|
||||
req.Header.Set("Content-Type", ctype)
|
||||
return c.Client.Do(req)
|
||||
}
|
||||
|
||||
func globalDiscoveryIdentity(addr string) string {
|
||||
return "global discovery server " + addr
|
||||
}
|
||||
|
||||
func ipv4Identity(port int) string {
|
||||
return fmt.Sprintf("IPv4 local broadcast discovery on port %d", port)
|
||||
}
|
||||
|
||||
func ipv6Identity(addr string) string {
|
||||
return fmt.Sprintf("IPv6 local multicast discovery on address %s", addr)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user