MCPcopy
hub / github.com/IceWhaleTech/CasaOS / GetCasaOSLogs

Method GetCasaOSLogs

service/system.go:428–443  ·  view source on GitHub ↗
(lineNumber int)

Source from the content-addressed store, hash-verified

426}
427
428func (s *systemService) GetCasaOSLogs(lineNumber int) string {
429 file, err := os.Open(filepath.Join(config.AppInfo.LogPath, fmt.Sprintf("%s.%s",
430 config.AppInfo.LogSaveName,
431 config.AppInfo.LogFileExt,
432 )))
433 if err != nil {
434 return err.Error()
435 }
436 defer file.Close()
437 content, err := io.ReadAll(file)
438 if err != nil {
439 return err.Error()
440 }
441
442 return string(content)
443}
444
445func GetDeviceAllIP() []string {
446 var address []string

Callers

nothing calls this directly

Calls 2

CloseMethod · 0.80
ErrorMethod · 0.45

Tested by

no test coverage detected