github.com/cockroachdb/cockroach@v20.2.0-alpha.1+incompatible/pkg/cli/start_windows.go (about)

     1  // Copyright 2017 The Cockroach Authors.
     2  //
     3  // Use of this software is governed by the Business Source License
     4  // included in the file licenses/BSL.txt.
     5  //
     6  // As of the Change Date specified in that file, in accordance with
     7  // the Business Source License, use of this software will be governed
     8  // by the Apache License, Version 2.0, included in the file
     9  // licenses/APL.txt.
    10  
    11  package cli
    12  
    13  import "os"
    14  
    15  // drainSignals are the signals that will cause the server to drain and exit.
    16  var drainSignals = []os.Signal{os.Interrupt}
    17  
    18  // quitSignal is the signal to recognize to dump Go stacks.
    19  var quitSignal os.Signal = nil
    20  
    21  func handleSignalDuringShutdown(os.Signal) {
    22  	// Windows doesn't indicate whether a process exited due to a signal in the
    23  	// exit code, so we don't need to do anything but exit with a failing code.
    24  	// The error message has already been printed.
    25  	os.Exit(1)
    26  }
    27  
    28  func maybeRerunBackground() (bool, error) {
    29  	return false, nil
    30  }
    31  
    32  func disableOtherPermissionBits() {
    33  	// No-op on windows, which does not support umask.
    34  }
    35  
    36  func useUnixSocketsInDemo() bool {
    37  	// No unix sockets on windows.
    38  	return false
    39  }