Coder Social home page Coder Social logo

docker-stellar-core's Introduction

Stellar Core Docker image

Docker Pulls

Docker Hub

The Docker images are published at satoshipay/stellar-core and come in multiple flavors that are available as tags:

  • Vanilla: just Stellar Core, example tags are 10.0.0 or latest.
  • AWS: comes with AWS CLI installed, example tags are 10.0.0-aws or latest-aws.
  • Google Cloud: comes with Google Cloud SDK installed, example tags are 10.0.0-gcloud or latest-gcloud. A Service Account is automatically configured if a key is provided via GCLOUD_SERVICE_ACCOUNT_KEY.
  • Azure: comes with Azure CLI installed, example tags are latest-azure. Required environment variables:
    • AZURE_STORAGE_ACCOUNT=<storage_account_name>
    • AZURE_STORAGE_KEY=<storage_account_key>

Configuration

The container can be fully configured via environment variables, see below.

There is also an example Docker Compose config โ€“ just run docker-compose -f docker-compose.example.yml up to get a functional node. Make sure to use a new NODE_SEED if you intend to run this in production!

Create node seed

If you don't have a node seed yet you can create one by running

docker run --rm -it --entrypoint '' satoshipay/stellar-core stellar-core gen-seed

Use the Secret seed only for the NODE_SEED env variable and tell other nodes your Public key.

Environment variables

All Stellar Core config options can be set via environment variables. Here we list the ones you probably want to set:

  • NODE_SEED: your secret seed, see above.

  • NETWORK_PASSPHRASE: default is Public Global Stellar Network ; September 2015 which is the public production network; use Test SDF Network ; September 2015 for the testnet.

  • DATABASE: default is sqlite3://stellar.db which you should definitely change for production, e.g., postgresql://dbname=stellar user=postgres host=postgres or postgresql://dbname=stellar user=postgres password=DATABASE_PASSWORD host=postgres (see DATABASE_PASSWORD).

  • DATABASE_PASSWORD: if provided, the string DATABASE_PASSWORD in the DATABASE variable is replace with its value. This is useful for providing passwords separately, e.g., via secrets in Kubernetes.

  • KNOWN_PEERS: comma-separated list of peers (ip:port) to connect to when below TARGET_PEER_CONNECTIONS, e.g., core-live-a.stellar.org:11625,core-live-b.stellar.org:11625,core-live-c.stellar.org:11625.

  • HISTORY: JSON of the following form:

    {
      "h1": {
        "get": "curl -sf http://history.stellar.org/prd/core-live/core_live_001/{0} -o {1}"
      }
    }
    
  • INITIALIZE_DB (default true): if set to true initializes the database if it hasn't been initialized before. Note: detecting whether the database has already been initialized is done via checking a file in the /data volume so the database will be re-initialized when the volume is recreated.

  • INITIALIZE_HISTORY_ARCHIVES: if set to true the history archives with a put command will be initialized if they haven't been initialized yet. Note: detecting whether an archive has already been initialized is done via checking a file in the /data volume so the archive will be re-initialized when the volume is recreated.

  • NODE_NAMES: comma-separated list of nodes with names (e.g., for using them in QUORUM_SET), for example:

    GCGB2S2KGYARPVIA37HYZXVRM2YZUEXA6S33ZU5BUDC6THSB62LZSTYH  sdf_watcher1,GCM6QMP3DLRPTAZW2UZPCPX2LF3SXWXKPMP3GKFZBDSF3QZGV2G5QSTK  sdf_watcher2,GABMKJM6I25XI4K7U6XWMULOUQIQ27BCTMLS6BYYSOWKTBUXVRJSXHYQ  sdf_watcher3
    
    
  • QUORUM_SET: JSON of the following form:

    [
      {
        "validators": [
          "GDQWITFJLZ5HT6JCOXYEVV5VFD6FTLAKJAUDKHAV3HKYGVJWA2DPYSQV you_can_add",
          "GANLKVE4WOTE75MJS6FQ73CL65TSPYYMFZKC4VDEZ45LGQRCATGAIGIA human_readable"
         ]
      },
      {
        "path": "1",
        "threshold_percent": 67,
        "validators": [
          "$self",
          "GDXJAZZJ3H5MJGR6PDQX3JHRREAVYNCVM7FJYGLZJKEHQV2ZXEUO5SX2 some_name"
        ]
      }
    ]
    

docker-stellar-core's People

Contributors

andrenarchy avatar istrau3 avatar remitaffin avatar meinharrd avatar

Watchers

James Cloos 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.