1.3.7: Merge pull request #191 from HSF/dev
(1) fix log rotation
(2) clean heartbeat before starting idds: idds can automatically clean heartbeats by checking the pids during start. However, for pod in k8s, every restart will have the same pids for idds daemons. As a result, iDDS thought the daemons are still running. However in fact, they are different daemons.