code: func SetLogfile(logfilePath string, opts ...os.FileMode) {
  	var err error
  	mode := os.FileMode(defaultFileMode)
  	// We open the file in append mode
  	if len(opts) > 0 {
  		mode = opts[0]
  	}
  	gLogFile, err := os.OpenFile(logfilePath, os.O_RDWR|os.O_CREATE|os.O_APPEND, mode)
  	if err != nil {
  		panic(err)
  	}
  	if _, err := gLogFile.Seek(0, os.SEEK_END); err != nil {
  		panic(err)
  	}
  	log.SetOutput(gLogFile)
  }
docs: // SetLogfile sets output file to put logging messages