Skip to content

Instantly share code, notes, and snippets.

@vivekanand01
Forked from SyntaxC4/main.py
Created February 20, 2020 12:03
Show Gist options
  • Save vivekanand01/5e62451ade05c5887578f5b5401aa951 to your computer and use it in GitHub Desktop.
Save vivekanand01/5e62451ade05c5887578f5b5401aa951 to your computer and use it in GitHub Desktop.
Connecting to Azure Redis Cache from Python
import redis
r = redis.StrictRedis(host='[cache-name].redis.cache.windows.net', port=6380, db=0, password='[access-key]', ssl=True)
r.set('foo','bar')
result = r.get('foo')
print result
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment