-
Notifications
You must be signed in to change notification settings - Fork 110
Using the Pocket Core Service Node Docker Image
The unique identifier for all of your Service Nodes instances. This GID will be provided by the Pocket team and will serve as the primary means of authentication with the Trusted MVP Dispatch Node.
Example
POCKET_CORE_SERVICE_GID=GID1
The IP, domain, loadbalancer or proxy that points to your Service Node.
NOTE: In case you are hosting more than one service node and/or will expect to receive higher traffic, we suggest to set it up behind a load balancer
Example
POCKET_CORE_SERVICE_IP=yourdomain.com
Example
POCKET_CORE_SERVICE_IP=x.x.x.x
Defaults to
POCKET_CORE_SERVICE_IP=127.0.0.1
The port to be used to connect using your POCKET_CORE_SERVICE_IP
NOTE: In case you are going to production, we suggest to use 443
and setup properly HTTPS
Example
POCKET_CORE_SERVICE_PORT=443
Defaults to
POCKET_CORE_SERVICE_PORT=80
Receives a JSON Array with the chains.json information, for more information about the structure
Defaults to
[]
Example
POCKET_CORE_CHAINS='[{"blockchain":{"name":"AION","netid":"32"},"port":"80","medium":"rpc","host":"myaionmasterynode.com"},{"blockchain":{"name":"ETH","netid":"4"},"port":"80","medium":"rpc","host":"mygethtestnetnode.com"}]'
Absolute path to the data directory (defaults to datadir
)
Defaults to
datadir
Example
POCKET_PATH_DATADIR=datadir
You can define Pocket Core’s configuration in various ways:
- Fetching configuration from S3 bucket
- Passing local configuration via env variable
- Mapping
datadir
or config folder to a folder with your custom configuration files
Receives a URL for S3 bucket or S3 bucket and directory path to download configurations from
If not provided, it will lookup your configuration using the POCKET_CORE_CHAINS
env variable.
The bucket should contain a file named chains.json
. Refer to the configuration files for Pocket Core MVP
In order to download the configuration properly from S3. You will also need to define the following environment variables:
- AWS_ACCESS_KEY_ID
- AWS_SECRET_ACCESS_KEY
- AWS_DEFAULT_REGION
Example with bucket:
POCKET_CORE_S3_CONFIG_URL=s3://mypocketconfigbucket/
Example with bucket subdirectory: sub-directory
POCKET_CORE_S3_CONFIG_URL=s3://mypocketconfigbucket/staging
$ docker run
-e POCKET_CORE_DISPATCH_IP=dispatch.pokt.network
-e POCKET_CORE_DISPATCH_PORT=443
-e POCKET_CORE_SERVICE_IP=yourservice.com
-e POCKET_CORE_SERVICE_PORT=80
-e POCKET_CORE_SERVICE_GID=GID99
-e POCKET_CORE_S3_CONFIG_URL=s3://mypocketconfigbucket/
-it poktnetwork/pocket-core:mvp-latest
$ docker run
-e POCKET_CORE_DISPATCH_IP=dispatch.pokt.network
-e POCKET_CORE_DISPATCH_PORT=443
-e POCKET_CORE_SERVICE_IP=yourservice.com
-e POCKET_CORE_SERVICE_PORT=80
-e POCKET_CORE_SERVICE_GID=GID99
-e POCKET_CORE_DEVELOPER_WHITELIST='["DEVELOPER_OVER_9999"]'
-e POCKET_CORE_SERVICE_WHITELIST='["SERVICE999"]'
-e POCKET_CORE_CHAINS='[{"blockchain":{"name":"AION","netid":"256","version":"0"},"port":"80","medium":"rpc","host":"myaionmainnetnode.com"},{"blockchain":{"name":"AION","netid":"32","version":"0"},"port":"80","medium":"rpc","host":"myaionmasterynode.com"},{"blockchain":{"name":"ETH","netid":"1","version":"0"},"port":"80","medium":"rpc","host":"mygethmainnetnode.com"},{"blockchain":{"name":"ETH","netid":"4","version":"0"},"port":"80","medium":"rpc","host":"mygethtestnetnode.com"}]'
-it poktnetwork/pocket-core:mvp-latest