I am currently starting to work on an app that will have a CLI client side and a server side. Since I wanted to dig into IPFS, I read the paper and I’m thinking to use IPFS to replace parts of the server for storing/distributing the data.
Now I have a few questions on the implementation/design side.
To give you an idea of the app architecture, think of Github. You have a cli side to add and push content, and server side to index/distribute the content.
So I’m aiming at the following architecture: - The server will be an always available IPFS node - It will pin any content pushed by the clients - It will have some custom web ui to browse the content - The cli client will also be an ipfs node - Adding content will add it to ipfs and ask the server to pull it (pin it)
No my questions:
As I understand, in order to use IPFS on the client the ipfs daemon needs to be running. However I don’t want to have the users to run ipfs daemon as an extra step. Is there a clean or subtle way to integrate the ipfs daemon on the cli client ? Again think git, when I use git commands there is no daemon running
Since the server will be always pinning any content from the clients when clients push content, is there a way to pull it on the server node directly given the client nodeid ? I mean is there a way to avoid all the DHT query and tell the node to get the value for the key directly from a specific nodeid ? This question is for both sides, when clients will download content, it would be great to get it directly from the server nodeid as first priority, and use other nodes as extra help if available
Related to (2), is there a way to disable the bitswap strategy or be permissive when clients/server ipfs nodes communicate ?