title: Mark standalone redis as read-only
body: <p>I want to mark a standalone Redis server (not a Redis-Cluster, not a Redis-Sentinel) as read-only. I have been googling for this for quite sometime but I don't seem to find a definite answer (Almost all answers point to Clustering or Sentinel). I was looking out for some config modification (<code>CONFIG SET something</code>).</p>
  <p>NOTE: <code>config set replica-read-only yes</code> does not make the current redis-server read-only, but only its replicas.</p>
  <p>My use-case basically is I am doing a migration wherein at some point I want to make the redis-server read-only. My application code can handle failures whenever a write call happens so that's not an issue.</p>
  <p>Also, if this is not directly possible from redis server, is there something that I can do in the client code that'll have the same effect (I am using redis-py as the client library)? (Although this is less than ideal)</p>
  <h3>Things that I've tried</h3>
  <ul>
  <li>Played around with <code>config set replica-read-only yes</code> and other configs. They don't seem to be applying the current redis-server.</li>
  <li>Tried marking a redis-server as a replica of itself (This was illogical, but just wanted to see if this worked), but turns out it deleted all keys in my local redis, so not something I can do.</li>
  </ul>