nanomock


Namenanomock JSON
Version 0.0.22 PyPI version JSON
download
home_pagehttps://github.com/gr0vity-dev/nanomock
SummaryCreate local dockerized nano-currency networks
upload_time2024-11-20 22:23:13
maintainerNone
docs_urlNone
authorgr0vity
requires_pythonNone
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # nanomock

A one click [nano-currency](https://nano.org) block-lattice environment on your local computer.
This project aims to easily spin up an integration environment with multiple nano nodes.
The local network is highly customizable.
All configuration is done inside the config file : `nanonet/nl_config.toml`

## prerequisites 

* python3.8+
* docker
* docker-compose 2

## Quickstart :

#### Install the library :

To install the library you can
- clone the respository and run `pip3 install .`
- or run `pip3 install nanomock`to download the latest version from PyPi

This gives you access to `nanomock {command}` command which will use `your_current_dir`as its entry point.

#### Spin up a network :

| Action            | Code                                              | Description  
| :----------       |:---------------------------------------------     | -----
| create            |`$ nanomock create`                                  | Create folders and node config 
| start             |`$ nanomock start`                                   | Start nodes (optional `--nodes`)
| init              |`$ nanomock init`                                    | Create Epochs Canary Burn and Vote weight distribution 
--------
#### Manage the network network :
| Action            | Code                                              | Description  
| :----------       |:---------------------------------------------     | -----
| status            |`$ nanomock status`                                  | Get status and block count for each node
| stop              |`$ nanomock stop`                                    | Stop nodes (optional `--nodes`)
| restart           |`$ nanomock restart`                                 | Restart all nodes  
| reset             |`$ nanomock reset`                                   | Delete data.ldb and wallets.ldb
| down              |`$ nanomock down`                                    | Remove all nodes
| destroy           |`$ nanomock destroy`                                 | Remove all nodes and data
| update            |`$ nanomock update `                                 | Pull and build latest containers

####  Query nodes :

Each node can be queried via RPC (see the [official documentation](https://docs.nano.org/commands/rpc-protocol/) )
| Action            | Code                                              | Description  
| :----------       |:---------------------------------------------     | -----
| rpc               |`$ nanomock rpc --payload '{"action" : "any_rpc"}'`  | Use nano_rpc commands (optional `--nodes`)


#### Configure the network :

`nl_config.toml` define all aspects of the network : genesis account, burn_amount, number of nodes, versions,...




            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/gr0vity-dev/nanomock",
    "name": "nanomock",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": null,
    "author": "gr0vity",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/f0/b6/db1307ef5cbc4db6b6bfb858589257ec4b81f024984d42ef0fad9dbb9742/nanomock-0.0.22.tar.gz",
    "platform": null,
    "description": "# nanomock\n\nA one click [nano-currency](https://nano.org) block-lattice environment on your local computer.\nThis project aims to easily spin up an integration environment with multiple nano nodes.\nThe local network is highly customizable.\nAll configuration is done inside the config file : `nanonet/nl_config.toml`\n\n## prerequisites \n\n* python3.8+\n* docker\n* docker-compose 2\n\n## Quickstart :\n\n#### Install the library :\n\nTo install the library you can\n- clone the respository and run `pip3 install .`\n- or run `pip3 install nanomock`to download the latest version from PyPi\n\nThis gives you access to `nanomock {command}` command which will use `your_current_dir`as its entry point.\n\n#### Spin up a network :\n\n| Action            | Code                                              | Description  \n| :----------       |:---------------------------------------------     | -----\n| create            |`$ nanomock create`                                  | Create folders and node config \n| start             |`$ nanomock start`                                   | Start nodes (optional `--nodes`)\n| init              |`$ nanomock init`                                    | Create Epochs Canary Burn and Vote weight distribution \n--------\n#### Manage the network network :\n| Action            | Code                                              | Description  \n| :----------       |:---------------------------------------------     | -----\n| status            |`$ nanomock status`                                  | Get status and block count for each node\n| stop              |`$ nanomock stop`                                    | Stop nodes (optional `--nodes`)\n| restart           |`$ nanomock restart`                                 | Restart all nodes  \n| reset             |`$ nanomock reset`                                   | Delete data.ldb and wallets.ldb\n| down              |`$ nanomock down`                                    | Remove all nodes\n| destroy           |`$ nanomock destroy`                                 | Remove all nodes and data\n| update            |`$ nanomock update `                                 | Pull and build latest containers\n\n####  Query nodes :\n\nEach node can be queried via RPC (see the [official documentation](https://docs.nano.org/commands/rpc-protocol/) )\n| Action            | Code                                              | Description  \n| :----------       |:---------------------------------------------     | -----\n| rpc               |`$ nanomock rpc --payload '{\"action\" : \"any_rpc\"}'`  | Use nano_rpc commands (optional `--nodes`)\n\n\n#### Configure the network :\n\n`nl_config.toml` define all aspects of the network : genesis account, burn_amount, number of nodes, versions,...\n\n\n\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Create local dockerized nano-currency networks",
    "version": "0.0.22",
    "project_urls": {
        "Homepage": "https://github.com/gr0vity-dev/nanomock"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2b9c98752ff4f7c3a106bb1f9ea42fa3e1063c3710693bb0c56fff38c0eeec64",
                "md5": "df883412dcf0adcef8db7724816235bc",
                "sha256": "5a9ef68d284103dafa009b56f8e8c79ce6f65bb5c6d7b0d955454b7310fe27dc"
            },
            "downloads": -1,
            "filename": "nanomock-0.0.22-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "df883412dcf0adcef8db7724816235bc",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 119969,
            "upload_time": "2024-11-20T22:23:12",
            "upload_time_iso_8601": "2024-11-20T22:23:12.131057Z",
            "url": "https://files.pythonhosted.org/packages/2b/9c/98752ff4f7c3a106bb1f9ea42fa3e1063c3710693bb0c56fff38c0eeec64/nanomock-0.0.22-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f0b6db1307ef5cbc4db6b6bfb858589257ec4b81f024984d42ef0fad9dbb9742",
                "md5": "cfe962a8bdceff53d795864f1344a8c4",
                "sha256": "e44a1de74910bf212f6047feabe66f549591b5f61b58bbab6ec15154238e8801"
            },
            "downloads": -1,
            "filename": "nanomock-0.0.22.tar.gz",
            "has_sig": false,
            "md5_digest": "cfe962a8bdceff53d795864f1344a8c4",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 72813,
            "upload_time": "2024-11-20T22:23:13",
            "upload_time_iso_8601": "2024-11-20T22:23:13.427222Z",
            "url": "https://files.pythonhosted.org/packages/f0/b6/db1307ef5cbc4db6b6bfb858589257ec4b81f024984d42ef0fad9dbb9742/nanomock-0.0.22.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-11-20 22:23:13",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "gr0vity-dev",
    "github_project": "nanomock",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [],
    "lcname": "nanomock"
}
        
Elapsed time: 0.46568s