Giter Site home page Giter Site logo

arch-internxt's Introduction

arch-internxt

Run your own "mini" internxt on your local computer with Docker

Prerequisites

Make sure you have installed Docker and Docker Compose on your development machine:

Installation

To run this project, you have to follow some steps first

Setup images

This script clone and build: bridge, complex and core-daemon(xcore)

bash setupImages.sh 

Update images

Check if there are new commit in the projects, using this script

bash pullAndBuild.sh 

Running the project

Once you have configured correctly your variables, you can run it

docker-compose up -d

Stop all containers

docker-compose stop

Remove all containers

docker-compose down

Configuration

You can change your variables in docker-compose.yaml

Add a renter

If you want to add a renter, you have to add a new renter service in docker-compose.yaml and change this variables

  renterX: # Service name
    image: renter-image
    container_name: renterX # Container name
    restart: always
    environment:
      network_private_extended_key_string: # Private key
      storjrenter_opts__networkOpts__rpcPort: # Rpc port
      storjrenter_opts__networkOpts__rpcAddress: # Your address is your service name
      storjrenter_opts__networkOpts__tunnelServerPort: # Tunnel server port
      storjrenter_opts__networkOpts__tunnelGatewayRange__min: # Tunnel gateway range min
      storjrenter_opts__networkOpts__tunnelGatewayRange__max: # Tunnel gateway range max
      storjrenter_opts__totalRenters: # Number of total renters in your network
      storjrenter_opts__renterOverlap: # Overlap renter
      storjrenter_opts__networkIndex: # Your network index

Change 2 variables in all renters:

  • totalRenters
  • networkIndex

Make sure that your renter config it's okay, consulting this project Complex-offsets

Add a xcore

If you want to add a xcore, change your service name, container name and your EXTERNAL_IP

  xcoreX: # Service name
    image: xcore-image
    container_name: # Container name 
    restart: always 
    environment:
      EXTERNAL_IP: # Your address is your service name

How to generate an HD Key

Here are the detailed steps for creating an HD key for configuration:

// require necessary libs, get entropy, and create a key
const HDKey = require('hdkey');
const seed = require('crypto').randomBytes(64);
const hdkey = HDKey.fromMasterSeed(seed);

// to keep for other future uses
console.log(hdkey.privateExtendedKey);

// deriving the key for complex use (detailed in sip32)
const complexKey = hdkey.derive("m/3000'/0'");

// this will output expected private key used in configs
console.log(complexKey.privateExtendedKey);

// for this config value in complex
let options = {};
options.networkPrivateExtendedKey = complexKey.privateExtendedKey;

// this is the key used in contracts and contacts
console.log(complexKey.publicExtendedKey);

How to interact with your containers

You can interact with them launching two commands

docker exec -it container-name command

Or

docker exec -it container-name /bin/sh

arch-internxt's People

Contributors

siralde avatar victorargento avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.