From f2855e466be0269649ac8926c025a43f99092778 Mon Sep 17 00:00:00 2001 From: vms Date: Mon, 15 Jun 2020 17:40:30 +0300 Subject: [PATCH] use relative paths in the IPFS node example --- examples/ipfs_node/src/main.rs | 11 ++++------- fluence-faas/README.md | 2 +- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/examples/ipfs_node/src/main.rs b/examples/ipfs_node/src/main.rs index f2c1a8b2..394c5bf8 100644 --- a/examples/ipfs_node/src/main.rs +++ b/examples/ipfs_node/src/main.rs @@ -19,12 +19,9 @@ use fluence_faas::IValue; use std::path::PathBuf; -const IPFS_MODULES_DIR: &str = "/Users/mike/dev/work/fluence/wasm/fce/bin/wasm_modules"; - -const IPFS_MODULES_CONFIG_PATH: &str = - "/Users/mike/dev/work/fluence/wasm/fce/examples/ipfs_node/Config.toml"; - -const IPFS_RPC: &str = "/Users/mike/dev/work/fluence/wasm/fce/bin/wasm_ipfs_rpc_wit.wasi.wasm"; +const IPFS_MODULES_DIR: &str = "../../bin/wasm_modules"; +const IPFS_MODULES_CONFIG_PATH: &str = "Config.toml"; +const IPFS_RPC: &str = "../../bin/wasm_ipfs_rpc_wit.wasi.wasm"; fn main() { let ipfs_rpc = std::fs::read(IPFS_RPC).unwrap(); @@ -44,7 +41,7 @@ fn main() { println!("ipfs node addresses are:\n{:?}", node_addresses); let result = ipfs_node - .call_code(&ipfs_rpc, "put", &[IValue::String("asdasdasd".to_string())]) + .call_code(&ipfs_rpc, "put", &[IValue::String("hello, world!".to_string())]) .unwrap(); println!("execution result {:?}", result); diff --git a/fluence-faas/README.md b/fluence-faas/README.md index 7b2ead3d..b103c8db 100644 --- a/fluence-faas/README.md +++ b/fluence-faas/README.md @@ -1,3 +1,3 @@ # Fluence FaaS -Fluence FaaS is intended to run various Wasm binaries. At now, it is in the heavily developing phase. +Fluence FaaS is intended to run various Wasm binaries. At now, it is in the heavily developing phase. For more details please see the IPFS [example](https://github.com/fluencelabs/fce/tree/master/examples/ipfs_node).