gemini support lfs cache and download #661
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
gemini::lfs::share_lfs
paras
bootstrap_node: bootstrap_node
file_hash: file_hash
hash_type: hash_type
file_size: file_size
origin: origin
for example
This method will send a Post request to the relay to share lfs
gemini::lfs::create_lfs_download_tunnel
create lfs download local ports
Paras
bootstrap_node: bootstrap_node
ztm_agent_port: ztm_agent_port
file_uri: file_uri
for example
{
"bootstrap_node":"https://gitmono.org/relay",
"ztm_agent_port":777,
"file_uri":"p2p://t14id7uQxwneJ2PnPtaA3GSUwxTx6HTaq1UkayQVWSPT/sha256/52c90a86cb034b7a1c4beb79304fa76bd0a6cbb7b168c3a935076c714bd1c6b6"
}
Return
local_port1, local_port2,...
Each port is for a remote peer