Attempt to set up upstart supervision. Returns 1 if successful. */
| 7195 | |
| 7196 | /* Attempt to set up upstart supervision. Returns 1 if successful. */ |
| 7197 | static int redisSupervisedUpstart(void) { |
| 7198 | const char *upstart_job = getenv("UPSTART_JOB"); |
| 7199 | |
| 7200 | if (!upstart_job) { |
| 7201 | serverLog(LL_WARNING, |
| 7202 | "upstart supervision requested, but UPSTART_JOB not found!"); |
| 7203 | return 0; |
| 7204 | } |
| 7205 | |
| 7206 | serverLog(LL_NOTICE, "supervised by upstart, will stop to signal readiness."); |
| 7207 | raise(SIGSTOP); |
| 7208 | unsetenv("UPSTART_JOB"); |
| 7209 | return 1; |
| 7210 | } |
| 7211 | |
| 7212 | /* Attempt to set up systemd supervision. Returns 1 if successful. */ |
| 7213 | static int redisSupervisedSystemd(void) { |
no test coverage detected