Added signal handling

Signed-off-by: David Henningsson <david.henningsson@canonical.com>