Trap SIGINT in Gradle plugin
Check if response is committed before tryying to forward

It' sthe best we can do, but the container seems to still use our error page
(it just can't have the status code that we asked for).

Fixes gh-748