There is a neo4j community version container running on the azure, and i was provided by the dns
http://[remote-address]:7687
if i do curl with proxy(px from github)(office recommended also), i able to get, bolt_routing, transaction, bolt_direct, neo4j_version, neo4j_edition all successfully,
And with 7474 port with web browser i also able to connect to the db and same with neo4j desktop by adding remote db.
but when i do with python neo4j driver, Cannot resolve address [remote-address]:7687
import neo4j,sys
link = "bolt://" + sys.argv[1]
print(f"Trying to connect to: {link}")
def exp():
try:
x = neo4j.GraphDatabase.driver(link, auth=("neo4j", "my_pswd"))
print(x.verify_connectivity())
except Exception as e:
print(e)
so, how to connect to a container hosted on azure ?
Update:
i tried to connect with IP of the azure instance running, but
Couldn't connect to [IP-address]:7687 (resolved to ('[IP-address]:7687',)):
Failed to establish connection to ResolvedIPv4Address(('[IP-address]', 7687)) (reason [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond)
it is connection through web and neo4j browser completely fine, only not through the python script.!!
I would recommend neo4j Aura. It is a fully managed cloud service and has a hassle free connection to a database. It is also has a free tier to try. See sample script to connect into it: