Fix traps in main.sh:
 - Make sure we exit on interrupt
 - Make sure clean-up commands are not executed twice