ipfs-shipyard / java-ipfs-http-client

A Java implementation of the HTTP IPFS API
MIT License
538 stars 243 forks source link

Couldn't connect to IPFS daemon at http://... #169

Closed cu3fb closed 1 year ago

cu3fb commented 4 years ago

my english is bad. when i create an IPFS instance: IPFS ipfs = new IPFS("/ip4/127.0.0.1/tcp/5001"); i want use another address like this: IPFS ipfs = new IPFS("/ip4/122.51.52.40/tcp/5001"); but i get this:

Exception in thread "main" java.lang.RuntimeException: Couldn't connect to IPFS daemon at http://122.51.52.40:5001/api/v0/version Is IPFS running?

i installed ipfs desktop v0.5.1

cloudgray commented 4 years ago

My English is bad either. Check config file of your IPFS Node. If the value of key "Addresses.API" is "/ip4/127.0.0.1/tcp/5001", change it to "/ip4/0.0.0.0/tcp/5001" In default, IPFS Node opens API port only to local request.

kevodwyer commented 1 year ago

I'm closing this issue as resolved, if that is not the case, feel free to re-open and provide more detail. Thanks.