Self-Host Appchain Infrastructure
Guidance for self-hosting your own Appchain Infrastructure
This process is under active development. To help improve this guide or for technical support running your own Appchain infrastructure, join our Discord. To report a bug, you can create a new issue in https://github.com/SyndicateProtocol/syndicate-appchains/issues.
Self-Hosting Overview
A Syndicate appchain is the full stack deployment that combines all of the components needed to send and confirm transactions, mine blocks, maintain chain history, and deposit and withdraw funds. Read more about the Syndicate Stack here. To self-host your own Syndicate Appchain means you must run and maintain all of those services and workflows. Luckily, the stack is entirely opensource so it is possible to run all of the infrastructure yourself!
This guide assumes that your Syndicate Appchain already exists and you have all of the Appchain configurations on-hand. If that is not the case, you may need to start with our 'GET STARTED' docs first to get your Appchain up and running, or contact Syndicate for support.
The following sections divide the stack into "RPC+Sequencer" and "Withdrawals" because their deployments are distinctly different. But keep in mind, to completely self-host a Syndicate appchain you must run both.
Developer Requirements
This guide assumes that the reader:
- is familiar with containerization and Docker
- is comfortable using
sshto execute commands on a remote machine - is proficient in running and maintaining infrastructure using a cloud provider
- has an AWS account and project available for running Withdrawals infra
- is familiar with AWS Trusted Execution Environments
- has access to GPU machines for one-time proof generation
- is familiar with Syndicate's opensource stack: https://github.com/SyndicateProtocol/syndicate-appchains
- has obtained all of their Appchain config from Syndicate
- has settlement chain funds
- has ownership of their appchain (access to the private key of the 'owner' wallet)
Self-Host an RPC+Sequencer Node
This section walks through how to run all of the components that support reading and writing transactions to the appchain.
No matter how you choose to run these services, you must manage your own networking configuration such as load balancing, firewalls, and TLS depending on your desired RPC node access (e.g. public vs private).
Option 1: Host via GCP Marketplace
The easiest way to run all of the necessary components here is to follow our Run an Appchain Node on GCP guide.
That convenient solution spins up all microservices in a GCP VM with the provided docker-compose file, a user-defined .env config, and disks auto-mounted for data storage.
Option 2: Host Anywhere with Docker Compose
Alternatively, you can can use the provided docker-compose file on any machine that has Docker installed.
Note the volume mounts for Nitro, Mchain, and the Ingestor data - those all need at least 100Gi disks attached. See the official Arbitrum Nitro docs for sizing recommendations.
Also, that docker-compose file assumes a .env file exists in the same directory. Create that file using the template below and fill in all of your appchain-specific values.
# Configure your Syndicate Appchain node here.
# Reach out to Syndicate for help generating the correct configuration for your specific appchain.
# --- Node Software Versions ---
SYND_APPCHAINS_VERSION=v1.0.12
SYND_NITRO_VERSION=eigenda-v3.6.4
# --- Global Configuration ---
RUST_LOG=info
APPCHAIN_CHAIN_ID=12345
# --- Translator Configuration ---
# The full list of available configurations can be found here:
# https://github.com/SyndicateProtocol/syndicate-appchains/blob/main/synd-translator/bin/synd-translator/src/config.rs
CONFIG_MANAGER_ADDRESS=...
# --- Mchain Configuration ---
# The full list of available configurations can be found here:
# https://github.com/SyndicateProtocol/syndicate-appchains/blob/main/synd-mchain/src/config.rs
SNAPSHOT_URL=https://...tar.gz
# --- Maestro Configuration ---
# The full list of available configurations can be found here:
# https://github.com/SyndicateProtocol/syndicate-appchains/blob/main/synd-maestro/src/config.rs
CHAIN_RPC_URLS={...}
# --- Batch Sequencer Configuration ---
# The full list of available configurations can be found here:
# https://github.com/SyndicateProtocol/syndicate-appchains/blob/main/synd-batch-sequencer/src/config.rs
SEQUENCING_RPC_URLS=https://...
SEQUENCING_ADDRESS=...
BATCHER_PRIVATE_KEY=...
# --- Settlement Ingestor Configuration ---
# The full list of available configurations can be found here:
# https://github.com/SyndicateProtocol/syndicate-appchains/blob/main/synd-chain-ingestor/src/config.rs
SETTLEMENT_INGESTOR_START_BLOCK=12345
SETTLEMENT_INGESTOR_WS_URLS=wss://...
# --- Sequencing Ingestor Configuration ---
# The full list of available configurations can be found here:
# https://github.com/SyndicateProtocol/syndicate-appchains/blob/main/synd-chain-ingestor/src/config.rs
SEQUENCING_INGESTOR_START_BLOCK=12345
SEQUENCING_INGESTOR_WS_URLS=wss://...
# --- Proposer Configuration ---
# The full list of available configurations can be found here:
# https://github.com/SyndicateProtocol/syndicate-appchains/blob/main/synd-withdrawals/synd-proposer/pkg/config/config.go
#
# !! NOTE: The proposer requires all withdrawals infra to be running first. So come back to this section once that is done to update these fields !!
MTLS_ENABLED_ENCLAVE=false
SETTLEMENT_CHAIN_ID=84532
ENCLAVE_RPC_URL=https://...
EIGEN_RPC_URL=https://...
ETHEREUM_RPC_URL=https://...
SETTLEMENT_RPC_URL=https://...
SEQUENCING_RPC_URL=https://...
TEE_MODULE_CONTRACT_ADDRESS=...
APPCHAIN_BRIDGE_ADDRESS=...
SEQUENCING_BRIDGE_ADDRESS=...
SEQUENCING_CONTRACT_ADDRESS=...
PRIVATE_KEY=...
# --- Nitro Configuration ---
# Refer to the Arbitrum Nitro documentation for all available configuration options:
# https://docs.arbitrum.io/run-arbitrum-node/run-full-node
# Note: Syndicate Appchain nodes have not been tested with all possible Nitro configurations. If you add overrides here that are not
# recommended or provided by Syndicate, you may experience unexpected behavior with your node.
NITRO_LOG__LEVEL=INFO
NITRO_CHAIN_ID=12345
NITRO_CHAIN_NAME=your-appchain-name
NITRO_CHAIN_INFO__JSON='[{...}]'All of those config values come from a mix of sources including your appchain config, RPC providers, your withdrawals infra, and other places. Reach out to Syndicate support if you need help.
Self-Host the Withdrawals Infra
We have a dedicated Withdrawals Infrastructure guide for this step because it is quite involved. Follow those instructions to run all of the withdrawals infra for your appchain.
Be sure to revisit the Proposer config (from the previous section) once you have all the withdrawals infra running. There are a few Proposer configs that will only be known after this section is complete.
Optional: Block Explorer
You can optionally run a block explorer for your appchain using a third party like Blockscout.
Blockscout is a self-hosted EVM block explorer you can deploy alongside your RPC+Sequencer node in Docker. You just need a JSON-RPC endpoint for your self-hosted RPC node and a PostgreSQL database. Their deployment docs are here: https://docs.blockscout.com/setup/deployment/docker-compose-deployment
Test
Now that you are completely self-hosting the entire Syndicate Appchain stack, you should test the core functionalities to ensure everything is healthy and configured properly.
Test Deposits and Withdrawals
To deposit appchain funds to your wallet, you first need settlement chain funds. Once you have that, you can connect your wallet to the Arbitrum Bridge tool and bridge those funds to your appchain.
You will need to add you appchain's bridge config to the Arbitrum Bridge UI as a custom chain (in testnet mode) in order to use it in the bridge UI dropdown. Reach out to Arbitrum support for help with this step.
To withdraw funds from your appchain, you need a wallet with appchain funds. Once you have that, you can connect that wallet to the Arbitrum Bridge tool and initiate a withdrawal from your appchain back to the settlement chain. From the Arbitrum Bridge UI you can initiate a withdrawal, then wait 2 hours (Syndicate fast-withdrawals challenge window time), then the UI will give you the option to "claim" the withdrawal in the Pending Transactions tab.
If depositing and withdrawals work as expected then your withdrawals infra is running and healthy!
Test Sending and Reading Transactions
To send a transaction to your appchain, first ensure you have appchain funds, then send a transaction like so:
cast send $YOUR_WALLET_ADDR --private-key $YOUR_WALLET_KEY --value 1000 --rpc-url $YOUR_SELF_HOSTED_RPC_URLYou should receive a transaction hash back, which you can then use to inspect the transaction details onchain:
cast rpc eth_getTransactionByHash $YOUR_TX_HASH --rpc-url $YOUR_SELF_HOSTED_RPC_URLIf all of these commands work as expected then your RPC+Sequencer node is running and healthy!
Troubleshooting
Here are some observability and troubleshooting tips to keep your Syndicate Appchain healthy:
- Almost all services expose prometheus metrics at
/metrics(some may simply need to be enabled with a flag first). Those values track critical metrics and errors to keep an eye on. - If the Nitro service is unhealthy, refer to the official nitro repo, Arbitrum documentation and OffchainLabs support channels for help
- All services have debug-level logging that can be enabled if needed
For technical support with your Appchain infrastructure, join our Discord.
To report a bug, you can create a new issue in https://github.com/SyndicateProtocol/syndicate-appchains/issues.