Ref T11592. By default, when PHP receives a SIGTERM, it just exits without running destructors.
This makes it difficult for us to release locks, free resources, terminate subprocesses, etc. We already fix this behavior in the daemon wrapper, but I want to extend this to all libphutil scripts so that everything terminates subprocesses correctly. Since pcntl_signal() can only accept one signal handler, that means we need to centralize signal handling.
This creates a centralized signal router and some formal signal handlers, and always installs basic routing behavior for SIGHUP (route, plus dump backtraces) and SIGTERM (exit, but run destructors).