some lint, renamed SIGINT to INT for posix/dash compliance, added better handling for INT, and added TERM handling in preparation for running in daemon mode with 'docker stop' support