Pocket Node Docker Setup

Overview

You can run a Pocket Node on any server, no matter what OS you use thanks to our Docker deployment artifact. This allows maximum setup flexibility for infrastructure operators.

Pre-installation:

If you don't have Docker, download it for your system:

Pull Docker image:

In order to download...

$   docker pull poktnetwork/pocket-core:rc-0.0.1

Configure docker-compose.yml:

Create a docker-compose.yml file and paste the following contents:

version: "2.1"
services:
    pocket-testnet:
        image: poktnetwork/pocket-core:rc-0.0.1
        privileged: true
        command: pocket-core start --seeds="<public key of dispatch node>@<ip of dispatch node>:26656"
        build: ./..
        expose:
            - "8081"
            - "26657"
            - "46656"
        environment:
            POCKET_CORE_KEY: <REPLACE WITH YOUR NODE PRIVATE KEY>
            POCKET_CORE_PASSPHRASE: "YOUR NODE PASSPHRASE>"
        networks:
            - pocket
        volumes:
            - "./chains.json:/home/app/.pocket/chains.json"
            - "./genesis.json:/home/app/.pocket/genesis.json"
networks:
    pocket:
        driver: bridge
# To run container:
$ docker-compose up

docker-compose.yml breakdown :

  • command: The command needed to start your Pocket Node
    • pocket-core start: (Required )The container command used to start the node
    • --seeds="<String>": ( Required) is used to connect you node to the blockchain by connecting to a dispatch node
  • expose: Exposes the ports to communicate with the Pocket Network
    • 8081: Is the Pocket RPC.
    • 26657: Tendermint RPC
    • 46656: Connecting to other nodes on the Pocket Network
  • environment: Env variable needed to identify your node
    • POCKET_CORE_KEY: Your account used to stakes private key
    • POCKET_CORE_PASSPHRASE: The passphrase used to encrypt your account
  • volumes: (configuration files <host file>:<docker container file> mapping):
    *.

Updated 12 days ago


Pocket Node Docker Setup


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.