https://github.com/ipfs/iptb
InterPlanetary TestBed 🌌🛌
https://github.com/ipfs/iptb
Last synced: about 1 year ago
JSON representation
InterPlanetary TestBed 🌌🛌
- Host: GitHub
- URL: https://github.com/ipfs/iptb
- Owner: ipfs
- License: mit
- Created: 2015-04-19T07:43:35.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2024-10-21T18:35:49.000Z (over 1 year ago)
- Last Synced: 2024-10-29T11:00:26.957Z (over 1 year ago)
- Language: Go
- Homepage:
- Size: 3.19 MB
- Stars: 163
- Watchers: 40
- Forks: 37
- Open Issues: 33
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# IPTB
`iptb` is a program used to create and manage a cluster of sandboxed nodes
locally on your computer. Spin up 1000s of nodes! Using `iptb` makes testing
libp2p networks easy!
For working with IPFS please see [ipfs/iptb-plugins](https://github.com/ipfs/iptb-plugins).
### Example (ipfs)
```
$ iptb auto -type -count 5
$ iptb start
$ iptb shell 0
$ echo $IPFS_PATH
/home/iptb/testbed/testbeds/default/0
$ echo 'hey!' | ipfs add -q
QmNqugRcYjwh9pEQUK7MLuxvLjxDNZL1DH8PJJgWtQXxuF
$ exit
$ iptb connect 0 4
$ iptb shell 4
$ ipfs cat QmNqugRcYjwh9pEQUK7MLuxvLjxDNZL1DH8PJJgWtQXxuF
hey!
```
### Usage
```
NAME:
iptb - iptb is a tool for managing test clusters of libp2p nodes
USAGE:
iptb [global options] command [command options] [arguments...]
VERSION:
2.0.0
COMMANDS:
auto create default testbed and initialize
testbed manage testbeds
help, h Shows a list of commands or help for one command
ATTRIBUTES:
attr get, set, list attributes
CORE:
init initialize specified nodes (or all)
start start specified nodes (or all)
stop stop specified nodes (or all)
restart restart specified nodes (or all)
run run command on specified nodes (or all)
connect connect sets of nodes together (or all)
shell starts a shell within the context of node
METRICS:
logs show logs from specified nodes (or all)
events stream events from specified nodes (or all)
metric get metric from node
GLOBAL OPTIONS:
--testbed value Name of testbed to use under IPTB_ROOT (default: "default") [$IPTB_TESTBED]
--quiet Suppresses extra output from iptb
--help, -h show help
--version, -v print the version
```
### Install
_Note: For MacOS golang v1.11 is needed to support plugin loading
(see [golang/go#24653](https://github.com/golang/go/issues/24653) for more information)_
```
$ go get github.com/ipfs/iptb
```
### Plugins
Plugins are now used to implement support for managing nodes. Plugins are
stored under `$IPTB_ROOT/plugins` (see [configuration](#configuration))
Plugins for the IPFS project can be found in [ipfs/iptb-plugins](https://github.com/ipfs/iptb-plugins).
### Configuration
By default, `iptb` uses `$HOME/testbed` to store created nodes. This path is configurable via the environment variables `IPTB_ROOT`.
### License
MIT