extract peer management from daemon
Merge pull request #25 from lipp/extract-peers

extract peer management from daemon