skycoin / teller

Skycoin exchange service
15 stars 30 forks source link

Logrotate #259

Closed gz-c closed 6 years ago

gz-c commented 6 years ago

Fix #255

Support for logrotate is added:

Add optional pidfile configuration for writing a pid file. This pid file is not locked, but is written after the boltdb is opened which does have a mutex lock. Two teller instances with different db's could overwrite the other's pidfile (this is a configuration error).

This pidfile should correspond to a logrotate config, and is used to identify the process for sending a SIGHUP which will cause teller to reopen its log file, allowing logrotate to archive the log file without losing any data.