mirror of
https://github.com/tailscale/tailscale.git
synced 2025-01-07 08:07:42 +00:00
ipn/ipnserver: remove Options.AllowQuit.
It was previously used by the MacOS client, but it now does something different. ipnserver should never obey a client's request to exit. Signed-off-by: David Anderson <dave@natulte.net>
This commit is contained in:
parent
c393f0bfae
commit
dec5d64593
@ -61,7 +61,6 @@ func main() {
|
|||||||
opts := ipnserver.Options{
|
opts := ipnserver.Options{
|
||||||
StatePath: *statepath,
|
StatePath: *statepath,
|
||||||
SurviveDisconnects: true,
|
SurviveDisconnects: true,
|
||||||
AllowQuit: false,
|
|
||||||
}
|
}
|
||||||
err = ipnserver.Run(context.Background(), logf, pol.PublicID.String(), opts, e)
|
err = ipnserver.Run(context.Background(), logf, pol.PublicID.String(), opts, e)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
@ -31,7 +31,6 @@
|
|||||||
type Options struct {
|
type Options struct {
|
||||||
StatePath string
|
StatePath string
|
||||||
SurviveDisconnects bool
|
SurviveDisconnects bool
|
||||||
AllowQuit bool
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func pump(logf logger.Logf, ctx context.Context, bs *ipn.BackendServer, s net.Conn) {
|
func pump(logf logger.Logf, ctx context.Context, bs *ipn.BackendServer, s net.Conn) {
|
||||||
@ -137,11 +136,8 @@ func Run(rctx context.Context, logf logger.Logf, logid string, opts Options, e w
|
|||||||
bs.Reset()
|
bs.Reset()
|
||||||
s.Close()
|
s.Close()
|
||||||
}
|
}
|
||||||
if opts.AllowQuit {
|
// Quitting not allowed, just keep going.
|
||||||
os.Exit(0)
|
bs.GotQuit = false
|
||||||
} else {
|
|
||||||
bs.GotQuit = false
|
|
||||||
}
|
|
||||||
}(ctx, bs, s, i)
|
}(ctx, bs, s, i)
|
||||||
|
|
||||||
bo.BackOff(ctx, nil)
|
bo.BackOff(ctx, nil)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user