Quickstart
This guide presents an end-to-end use case, demonstrating Debox's basic functionality and approach to sharing data between nodes. At its core, Debox consists of a daemon that listens to commands from a Debox client. In this example we will be using the Debox CLI client.
Step 1: Install Debox
See Installation section.
Step 2: Launch Debox
- Windows
- macOS
- Linux
-
Launch Debox daemon (accept the disclaimer when prompted)
.\debox.exeOutput:
(truncated)Daemon | Debox v0.1.0Daemon | Listening on 127.0.0.1:35350 -
Open up another terminal to execute the remaining commands
-
Intialize IPFS to provision all necessary files for the IPFS daemon
Runipfs initonly once after installationRunning
ipfs initcommand more than once will result in an error.\debox-cli.exe ipfs initOutput:
Success -
Start the IPFS daemon
.\debox-cli.exe ipfs daemon startOutput:
SuccessAccept Windows security pop-upClick
Allowfor IPFS daemon to start
-
Start Debox Keeper
.\debox-cli.exe keeper startOutput:
SuccessAccept Windows security pop-upClick
Allowfor Debox Keeper to start
-
Launch Debox daemon (accept the disclaimer when prompted)
./deboxOutput:
(truncated)Daemon | Debox v0.1.0Daemon | Listening on 127.0.0.1:35350 -
Open up another terminal to execute the remaining commands
-
Intialize IPFS to provision all necessary files for the IPFS daemon
Runipfs initonly once after installationRunning
ipfs initcommand more than once will result in an error./debox-cli ipfs initOutput:
Success -
Start the IPFS daemon
./debox-cli ipfs daemon startOutput:
Success -
Start Debox Keeper
./debox-cli keeper startOutput:
Success
-
Launch Debox daemon (accept the disclaimer when prompted)
./deboxOutput:
(truncated)Daemon | Debox v0.1.0Daemon | Listening on 127.0.0.1:35350 -
Open up another terminal to execute the remaining commands
-
Intialize IPFS to provision all necessary files for the IPFS daemon
Runipfs initonly once after installationRunning
ipfs initcommand more than once will result in an error./debox-cli ipfs initOutput:
Success -
Start the IPFS daemon
./debox-cli ipfs daemon startOutput:
Success -
Start Debox Keeper
./debox-cli keeper startOutput:
Success
Step 3: Connect to Debox Community Share
In order to connect to a Debox Share, you need an Invite - a base58 encoded string containing all the information that you need to request to join by sending a Pass (a request for access).
Debox offers a community Share that automatically accepts all Passes for users to test out the sharing functionality.
Debox community Share Invite: 4jqgs5CSNLusSMDEaEsTcHvEsDdjvqC2oXEFmcXAQginurd4gDwhfL5UaHjNPs9sVBKeCcXaRmsNrcxit3uz4SWzpLazU1AToP7nKuw4CdMbTfkYpWtnM15z7F5VhqM2xXiEwWKBNf2nT7e4aAkLWWm67sDX6EiBEfMW9768m2gCoVzPoz9KoqYiuxLAGLe28NFAU3tUsx
- Windows
- macOS
- Linux
-
Use the Invite to request access to the Debox community Share
.\debox-cli.exe pass create 4jqgs5CSNLusSMDEaEsTcHvEsDdjvqC2oXEFmcXAQginurd4gDwhfL5UaHjNPs9sVBKeCcXaRmsNrcxit3uz4SWzpLazU1AToP7nKuw4CdMbTfkYpWtnM15z7F5VhqM2xXiEwWKBNf2nT7e4aAkLWWm67sDX6EiBEfMW9768m2gCoVzPoz9KoqYiuxLAGLe28NFAU3tUsxOutput:
PassCreateOutput("Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76")You will have a different Pass ID (pid) from the one aboveEach user has their own unique Pass ID
-
List your pending Passes to confirm that the Pass was successfully sent
.\debox-cli.exe pass pendingOutput:
PassPendingOutput([PassPendingInfo { pid: "Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76" }]) -
The Debox community Share will automatically approve the Pass within a few seconds. Now, join the Share
.\debox-cli.exe pass join Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76Output:
PassJoinOutput(ShareInfo { id: "8GmPkVqh8zYFiQgZVXjHFuNSg9VPUYmaygmMRLstJ7tQ", path: "/CommunityShare" })
-
Use the Invite to request access to the Debox community Share
./debox-cli pass create 4jqgs5CSNLusSMDEaEsTcHvEsDdjvqC2oXEFmcXAQginurd4gDwhfL5UaHjNPs9sVBKeCcXaRmsNrcxit3uz4SWzpLazU1AToP7nKuw4CdMbTfkYpWtnM15z7F5VhqM2xXiEwWKBNf2nT7e4aAkLWWm67sDX6EiBEfMW9768m2gCoVzPoz9KoqYiuxLAGLe28NFAU3tUsxOutput:
PassCreateOutput("Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76")You will have a different Pass ID (pid) from the one aboveEach user has their own unique Pass ID
-
List your pending Passes to confirm that the Pass was successfully sent
./debox-cli pass pendingOutput:
PassPendingOutput([PassPendingInfo { pid: "Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76" }]) -
The Debox community Share will automatically approve the Pass within a few seconds. Now, join the Share
./debox-cli pass join Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76Output:
PassJoinOutput(ShareInfo { id: "8GmPkVqh8zYFiQgZVXjHFuNSg9VPUYmaygmMRLstJ7tQ", path: "/CommunityShare" })
-
Use the Invite to request access to the Debox community Share
./debox-cli pass create 4jqgs5CSNLusSMDEaEsTcHvEsDdjvqC2oXEFmcXAQginurd4gDwhfL5UaHjNPs9sVBKeCcXaRmsNrcxit3uz4SWzpLazU1AToP7nKuw4CdMbTfkYpWtnM15z7F5VhqM2xXiEwWKBNf2nT7e4aAkLWWm67sDX6EiBEfMW9768m2gCoVzPoz9KoqYiuxLAGLe28NFAU3tUsxOutput:
PassCreateOutput("Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76")You will have a different Pass ID (pid) from the one aboveEach user has their own unique Pass ID
-
List your pending Passes to confirm that the Pass was successfully sent
./debox-cli pass pendingOutput:
PassPendingOutput([PassPendingInfo { pid: "Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76" }]) -
The Debox community Share will automatically approve the Pass within a few seconds. Now, join the Share
./debox-cli pass join Ed4eiQBSA3dnyxHuJwSrtGCRAwxJzAYQDTgRfxTcCL76Output:
PassJoinOutput(ShareInfo { id: "8GmPkVqh8zYFiQgZVXjHFuNSg9VPUYmaygmMRLstJ7tQ", path: "/CommunityShare" })
Step 4: Retrieve Data
- Windows
- macOS
- Linux
-
Retrieve the contents of the Debox community Share
.\debox-cli.exe files pull /CommunityShareOutput:
Success -
List the files in your local Debox fs to see what was retrieved from the Debox community Share
.\debox-cli.exe files ls /CommunityShareOutput:
FilesLsOutput([FileInfo { name: "hello.txt", crtime: SystemTime { tv_sec: 1697054776, tv_nsec: 0 }, mtime: SystemTime { tv_sec: 1697054776, tv_nsec: 0 }, is_dir: false, size: 14 }, FileInfo { name: "debox.png", crtime: SystemTime { tv_sec: 1697054800, tv_nsec: 0 }, mtime: SystemTime { tv_sec: 1697054800, tv_nsec: 0 }, is_dir: false, size: 196284 }]) -
Copy the retrieved
hello.txtto your local fs from your local Debox fs.\debox-cli.exe files get /CommunityShare/hello.txt ~\Documents\hello.txtOutput:
Success -
Check the contents of
hello.txtcat ~\Documents\hello.txtOutput:
Hello Debox! -
Congratulations! You have completed the Debox quickstart.
-
Retrieve the contents of the Debox community Share
./debox-cli files pull /CommunityShareOutput:
Success -
List the files in your local Debox fs to see what was retrieved from the Debox community Share
./debox-cli files ls /CommunityShareOutput:
FilesLsOutput([FileInfo { name: "hello.txt", crtime: SystemTime { tv_sec: 1697054776, tv_nsec: 0 }, mtime: SystemTime { tv_sec: 1697054776, tv_nsec: 0 }, is_dir: false, size: 14 }, FileInfo { name: "debox.png", crtime: SystemTime { tv_sec: 1697054800, tv_nsec: 0 }, mtime: SystemTime { tv_sec: 1697054800, tv_nsec: 0 }, is_dir: false, size: 196284 }]) -
Copy the retrieved
hello.txtto your local fs from your local Debox fs./debox-cli files get /CommunityShare/hello.txt ~/Documents/hello.txtOutput:
Success -
Check the contents of
hello.txtcat ~/Documents/hello.txtOutput:
Hello Debox! -
Congratulations! You have completed the Debox quickstart.
-
Retrieve the contents of the Debox community Share
./debox-cli files pull /CommunityShareOutput:
Success -
List the files in your local Debox fs to see what was retrieved from the Debox community Share
./debox-cli files ls /CommunityShareOutput:
FilesLsOutput([FileInfo { name: "hello.txt", crtime: SystemTime { tv_sec: 1697054776, tv_nsec: 0 }, mtime: SystemTime { tv_sec: 1697054776, tv_nsec: 0 }, is_dir: false, size: 14 }, FileInfo { name: "debox.png", crtime: SystemTime { tv_sec: 1697054800, tv_nsec: 0 }, mtime: SystemTime { tv_sec: 1697054800, tv_nsec: 0 }, is_dir: false, size: 196284 }]) -
Copy the retrieved
hello.txtto your local fs from your local Debox fs./debox-cli files get /CommunityShare/hello.txt ~/Documents/hello.txtOutput:
Success -
Check the contents of
hello.txtcat ~/Documents/hello.txtOutput:
Hello Debox! -
Congratulations! You have completed the Debox quickstart.
Next Steps
We are currently working on the following sections to offer users a deeper dive into Debox's functionality:
- Guides (practical use cases of Debox)
- Concepts (an indepth conceptual look into Debox's architecture)
- API reference (a reference for building applications on top of Debox)
So, please, check back soon!