/** * @param NodeBuilder $node * @return NodeBuilder */ protected function appendProcessControlTo(NodeBuilder $node) { return $node->enumNode('expect')->info(<<<INFO fork - Upstart will expect the process executed to call fork(2) exactly once. daemon - Upstart will expect the process executed to call fork(2) exactly twice. stop - Specifies that the job's main process will raise the SIGSTOP signal to indicate that it is ready. init(8) will wait for this signal and then: - Immediately send the process SIGCONT to allow it to continue. - Run the job's post-start script (if any). Only then will Upstart consider the job to be running. INFO )->values(['fork', 'deamon', 'stop'])->validate()->ifNull()->thenUnset()->end()->end()->enumNode('killSignal')->info('Specifies the stopping signal, SIGTERM by default, a job\'s main process will receive when stopping the running job.')->values(['SIGHUP', 'SIGINT', 'SIGQUIT', 'SIGILL', 'SIGTRAP', 'SIGIOT', 'SIGBUS', 'SIGFPE', 'SIGKILL', 'SIGUSR1', 'SIGSEGV', 'SIGUSR2', 'SIGPIPE', 'SIGALRM', 'SIGTERM', 'SIGSTKFLT', 'SIGCHLD', 'SIGCONT', 'SIGSTOP', 'SIGTSTP', 'SIGTTIN', 'SIGTTOU', 'SIGURG', 'SIGXCPU', 'SIGXFSZ', 'SIGVTALRM', 'SIGPROF', 'SIGWINCH', 'SIGIO', 'SIGPWR'])->end()->integerNode('killTimeout')->info('The number of seconds Upstart will wait before killing a process. The default is 5 seconds.')->min(1)->end()->enumNode('reloadSignal')->info('Specifies the signal that Upstart will send to the jobs main process when the job needs to be reloaded (the default is SIGHUP).')->values(['SIGHUP', 'SIGINT', 'SIGQUIT', 'SIGILL', 'SIGTRAP', 'SIGIOT', 'SIGBUS', 'SIGFPE', 'SIGKILL', 'SIGUSR1', 'SIGSEGV', 'SIGUSR2', 'SIGPIPE', 'SIGALRM', 'SIGTERM', 'SIGSTKFLT', 'SIGCHLD', 'SIGCONT', 'SIGSTOP', 'SIGTSTP', 'SIGTTIN', 'SIGTTOU', 'SIGURG', 'SIGXCPU', 'SIGXFSZ', 'SIGVTALRM', 'SIGPROF', 'SIGWINCH', 'SIGIO', 'SIGPWR'])->end(); }
/** * @param NodeBuilder $nodeBuilder * * @return ArrayNodeDefinition */ private function buildConfigNode(NodeBuilder $nodeBuilder) { return $nodeBuilder->enumNode('serializer')->values([self::SERIALIZER_JSON_ENCODE, self::SERIALIZER_JSON_GROUP_ENCODE, self::SERIALIZER_JMS_SERIALIZER])->end()->arrayNode('serialize_groups')->prototype('scalar')->end()->end()->scalarNode('cors_allow_origin_regex')->end()->arrayNode('cors_allow_headers')->prototype('scalar')->end()->end()->integerNode('cors_max_age')->end(); }