mirror of
https://github.com/fluencelabs/aqua.git
synced 2024-12-13 02:05:32 +00:00
7c711f15e4
* fix path * fix ipfs * fix pathes
19 lines
337 B
Plaintext
19 lines
337 B
Plaintext
module IpfsExports
|
|
|
|
import "@fluencelabs/aqua-ipfs/ipfs-api.aqua"
|
|
import "run-builtins/run-builtins.aqua"
|
|
|
|
|
|
export uploadFile
|
|
|
|
const ON_PEER ?= HOST_PEER_ID
|
|
|
|
func uploadFile(path: string) -> UploadResult:
|
|
on ON_PEER:
|
|
multiaddr <- get_external_api_multiaddr(ON_PEER)
|
|
result <- LocalIpfs.uploadFile(path, multiaddr)
|
|
<- result
|
|
|
|
|
|
|