Add shutdown support
Merge pull request #13 from aluebs/alarm

Add shutdown support