diff --git a/src/redis.c b/src/redis.c index c1b269596..eb8bfbc65 100644 --- a/src/redis.c +++ b/src/redis.c @@ -3576,6 +3576,13 @@ int main(int argc, char **argv) { } j++; } + if (server.sentinel_mode && configfile && *configfile == '-') { + redisLog(REDIS_WARNING, + "Sentinel config from STDIN not allowed."); + redisLog(REDIS_WARNING, + "Sentinel needs config file on disk to save state. Exiting..."); + exit(1); + } if (configfile) server.configfile = getAbsolutePath(configfile); resetServerSaveParams(); loadServerConfig(configfile,options);