I have installed Memcached on an Azure VM server (Ubuntu). I now need to connect to this from my Python program that runs elsewhere.
When they were installed on the same server, this worked:
import memcache
MEMCACHE_SOCKET_PATH = 'unix:<path_to>/memcached.sock'
memcache_client = memcache.Client([MEMCACHE_SOCKET_PATH], debug=0)
Now I'm not sure what to use for MEMCACHE_SOCKET_PATH. The VM running Memcached has a static IP address and I have created an endpoint (opened a port) to 11211. memcached.sock sits in the home directory.
This is how I am running Memcached on the VM:
memcached -d -m 500 -s $HOME/memcached.sock -P $HOME/memcached.pid