Skip to content

Instantly share code, notes, and snippets.

@winder
Last active July 7, 2023 12:56
Show Gist options
  • Save winder/8e167d94817370c8ed2e8579432f9003 to your computer and use it in GitHub Desktop.
Save winder/8e167d94817370c8ed2e8579432f9003 to your computer and use it in GitHub Desktop.
Conduit Private Network
# Log verbosity: PANIC, FATAL, ERROR, WARN, INFO, DEBUG, TRACE
log-level: INFO
# If no log file is provided logs are written to stdout.
#log-file:
# Number of retries to perform after a pipeline plugin error.
retry-count: 10
# Time duration to wait between retry attempts.
retry-delay: "1s"
# Optional filepath to use for pidfile.
#pid-filepath: /path/to/pidfile
# Whether or not to print the conduit banner on startup.
hide-banner: false
# When enabled prometheus metrics are available on '/metrics'
metrics:
mode: OFF
addr: ":9999"
prefix: "conduit"
# The importer is typically an algod follower node.
importer:
name: algod
config:
# The mode of operation, either "archival" or "follower".
# * archival mode allows you to start processing on any round but does not
# contain the ledger state delta objects required for the postgres writer.
# * follower mode allows you to use a lightweight non-archival node as the
# data source. In addition, it will provide ledger state delta objects to
# the processors and exporter.
mode: "follower"
# Algod API address.
netaddr: "http://algod-follower:8080"
# Algod API token.
token: "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
# Zero or more processors may be defined to manipulate what data
# reaches the exporter.
processors:
# An exporter is defined to do something with the data.
exporter:
name: postgresql
config:
# Pgsql connection string
# See https://github.com/jackc/pgconn for more details
connection-string: "host=db port=5432 user=algorand password=algorand dbname=conduitdb"
# Maximum connection number for connection pool
# This means the total number of active queries that can be running
# concurrently can never be more than this
max-conn: 20
version: '3'
services:
algod-private:
image: "algorand/algod:master"
ports:
- 4190:8080
- 4191:7833
environment:
TOKEN: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
ADMIN_TOKEN: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
GOSSIP_PORT: 10000
algod-follower:
image: "algorand/algod:master"
# the genesis file must be downloaded from algod-private
# if this image starts first, keep restarting until algod-private
# is available.
restart: unless-stopped
# follower node is internal
ports:
- 5190:8080 # exposed for testing.
environment:
TOKEN: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
ADMIN_TOKEN: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
PROFILE: conduit
GENESIS_ADDRESS: algod-private:8080
PEER_ADDRESS: algod-private:10000
depends_on:
- algod-private
conduit:
image: "algorand/conduit:1.2.0"
restart: unless-stopped
volumes:
- type: bind
source: $PWD/conduit.yml
target: /etc/algorand/conduit.yml
depends_on:
- db
- algod-follower
db:
image: "postgres:13-alpine"
environment:
POSTGRES_USER: algorand
POSTGRES_PASSWORD: algorand
POSTGRES_DB: conduitdb
indexer:
image: algorand/indexer:3.0.0
ports:
- "8980:8980"
restart: unless-stopped
command: daemon
environment:
INDEXER_POSTGRES_CONNECTION_STRING: "host=db port=5432 user=algorand password=algorand dbname=conduitdb sslmode=disable"
depends_on:
- db
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment