 <p>I decided to use the <code>timeout</code> command to wrap the redis-cli command. It seems to work very well for my purposes! </p> <pre><code>timeout 3 redis-cli -h 10.10.10.10 -p 26379 SENTINEL MASTER testing </code></pre>