MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / bgServerInit

Function bgServerInit

cmd/cql/internal/cfg.go:137–151  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

135}
136
137func bgServerInit() {
138 if tmpPath == "" {
139 tmpPath = os.TempDir()
140 }
141 logPath := filepath.Join(tmpPath, "covenant_service.log")
142 bgLog, err := os.OpenFile(logPath, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, 0644)
143 if err != nil {
144 ConsoleLog.Errorf("open log file failed: %s, %v", logPath, err)
145 SetExitStatus(1)
146 Exit()
147 }
148
149 log.SetOutput(bgLog)
150 log.SetStringLevel(bgLogLevel, log.InfoLevel)
151}
152
153// readMasterKey reads the password of private key from terminal
154func readMasterKey(skip bool) string {

Callers 3

runMirrorFunction · 0.85
runExplorerFunction · 0.85
runAdapterFunction · 0.85

Calls 5

SetOutputFunction · 0.92
SetStringLevelFunction · 0.92
SetExitStatusFunction · 0.85
ExitFunction · 0.85
ErrorfMethod · 0.80

Tested by

no test coverage detected