2024-09-02 23:51:41 -04:00
2024-09-02 23:51:41 -04:00
2017-08-08 08:14:27 -04:00
2024-09-02 23:29:36 -04:00
2024-09-02 23:29:36 -04:00
2017-08-06 15:10:41 -04:00
2024-09-02 23:38:32 -04:00
2024-09-02 23:51:41 -04:00
2018-01-11 11:47:41 -05:00
2024-09-02 23:28:19 -04:00

docker testnet

Run and manage your own local I2P network with Docker.

Installing

Install requirements and add your user to docker group (security notes):

sudo apt install docker.io python3 python3-venv
sudo gpasswd -a your-user docker

Pull docker image:

sudo docker pull purplei2p/i2pd 

Clone the repo:

git clone https://github.com/l-n-s/docker-testnet && cd docker-testnet

Create virtual environment and install:

python3 -m venv venv
source venv/bin/activate
pip install .

Usage

Read help message:

testnetctl -h

Start a network:

testnetctl start

Or you may want to start a network with some nodes and floodfills:

testnetctl start --nodes 10 --floodfills 5

Add 5 floodfill nodes and 10 regular nodes:

testnetctl add 5 --floodfill
testnetctl add 10

Show network statistics overview:

testnetctl status

Show individual node information:

testnetctl inspect d34db33f1001

Remove couple of nodes:

testnetctl remove d34db33f1001 3f1001d34db3

Create I2P tunnel (options are specified exactly as key=value without spaces):

testnetctl create_tunnel d34db33f1001 test-tunnel type=http host=127.0.0.1 port=8888 keys=test.dat

Stop a network and quit:

testnetctl stop

Configuration

Takes environment variables for configuration:

I2PD_IMAGE   -  docker image to use
NETNAME      -  docker network name
DEFAULT_ARGS -  default arguments for binary

    docker build -t geti2p/i2p .
    docker run \
        -e JVM_XMX=256m \
        -v i2phome:/i2p/.i2p \
        -v i2ptorrents:/i2psnark \
        -p 16657:7657 \
        -p 12345:12345 \
        -p 54321:54321/udp \
        geti2p/i2p-testnet:latest
Description
No description provided
Readme MIT 77 KiB
Languages
Python 98.9%
Dockerfile 1.1%