SKALE Node CLI, part of the SKALE suite of validator tools, is the command line interface to setup, register and maintain your SKALE node. It comes in three distinct build types: Standard (for validator nodes), Passive (for dedicated sChain synchronization), and Fair.
- Installation
- Standard Node Usage (
skale- Normal Build) - Passive Node Usage (
skale- Passive Build) - Fair Node Usage (
fair) - Exit codes
- Development
Ensure that the following packages are installed: docker, docker-compose (1.27.4+)
This binary (skale-VERSION-OS) is used for managing SKALE validator nodes.
# Replace {version} with the desired release version (e.g., 3.0.0)
CLI_VERSION={version} && \
sudo -E bash -c "curl -L https://github.com/skalenetwork/node-cli/releases/download/$CLI_VERSION/skale-$CLI_VERSION-`uname -s`-`uname -m` > /usr/local/bin/skale"This binary (skale-VERSION-OS-fair) is used for managing nodes on the Fair network.
# Replace {version} with the desired release version (e.g., 3.0.0)
CLI_VERSION={version} && \
sudo -E bash -c "curl -L https://github.com/skalenetwork/node-cli/releases/download/$CLI_VERSION/skale-$CLI_VERSION-`uname -s`-`uname -m`-fair > /usr/local/bin/fair"Apply executable permissions to the downloaded binary (adjust name accordingly):
# For Standard or Passive binary
sudo chmod +x /usr/local/bin/skale
# For Fair binary
sudo chmod +x /usr/local/bin/fairTest the installation:
# Standard or Passive build
skale --help
# Fair build
fair --helpCommands available in the standard skale binary for managing nodes.
Print build info for the skale (normal) binary.
skale infoPrint version number for the skale (normal) binary.
skale versionOptions:
--short- prints version only, without additional text.
Prefix:
skale node
Get base info about the standard SKALE node.
skale node infoOptions:
-f/--format json/text- optional.
Initialize a standard SKALE node on the current machine.
⚠️ Avoid re-initializing a node that’s already initialized: Runskale node infofirst to confirm the current initialization state.
skale node init [ENV_FILE]Arguments:
ENV_FILE- path to .env file (required).
Required environment variables in ENV_FILE:
SGX_SERVER_URL- SGX server URL.BLOCK_DEVICE- Absolute path to a dedicated raw block device (e.g. /dev/sdc)DOCKER_LVMPY_VERSION- Version ofdocker-lvmpy.NODE_VERSION- Version ofskale-node.ENDPOINT- RPC endpoint of the network where SKALE Manager is deployed.MANAGER_CONTRACTS- SKALE Managermessage_proxy_mainnetcontract alias or address.IMA_CONTRACTS- IMAskale_managercontract alias or address.FILEBEAT_HOST- URL of the Filebeat log server.ENV_TYPE- Environment type (e.g., 'mainnet', 'testnet', 'qanet', 'devnet').
In
MANAGER_CONTRACTSandIMA_CONTRACTSfields, if you are using a recognized network (e.g., 'Mainnet', 'Holesky', 'local'), you can use a recognized alias (e.g., 'production', 'grants'). You can check the list of recognized networks and aliases in contract deployments. :warning: If you are using a custom network or a contract which isn't recognized by the underlyingskale-contractslibrary, you MUST provide a direct contract address.
Optional variables:
TG_API_KEY- Telegram API keyTG_CHAT_ID- Telegram chat IDMONITORING_CONTAINERS- Enable monitoring containers (cadvisor,node-exporter).
Restore a standard SKALE node on another machine from a backup.
skale node restore [BACKUP_PATH] [ENV_FILE]Arguments:
BACKUP_PATH- Path to the archive created byskale node backup.ENV_FILE- Path to .env file with configuration for the restored node.
Generate a backup archive of the standard SKALE node's state.
skale node backup [BACKUP_FOLDER_PATH]Arguments:
BACKUP_FOLDER_PATH- Path to the folder where the backup file will be saved.
Register the standard node with the SKALE Manager contract.
skale node register --name <NODE_NAME> --ip <PUBLIC_IP> --domain <DOMAIN_NAME> [--port <BASE_PORT>]Required arguments:
--ip- Public IP for RPC connections and consensus.--domain/-d- SKALE node domain name.--name- SKALE node name.
Optional arguments:
--port- Base port for node sChains (default:10000).
Update the standard SKALE node software and configuration.
skale node update [ENV_FILEPATH] [--yes]Arguments:
ENV_FILEPATH- Path to the .env file containing potentially updated parameters.
Options:
--yes- Update without confirmation prompt.
Turn off the standard SKALE node containers.
skale node turn-off [--maintenance-on] [--yes]Options:
--maintenance-on- Set node to maintenance mode before turning off.--yes- Turn off without confirmation.
Turn on the standard SKALE node containers.
skale node turn-on [ENV_FILEPATH] [--maintenance-off] [--yes]Arguments:
ENV_FILEPATH- Path to the .env file.
Options:
--maintenance-off- Turn off maintenance mode after turning on.--yes- Turn on without additional confirmation.
Control the node's maintenance status in SKALE Manager.
# Set maintenance ON
skale node maintenance-on [--yes]
# Set maintenance OFF
skale node maintenance-offOptions:
--yes- Perform action without additional confirmation.
Set the standard node's domain name.
skale node set-domain --domain <DOMAIN_NAME> [--yes]Required Options:
--domain/-d- The new SKALE node domain name.
Options:
--yes- Set without additional confirmation.
Get the node signature for a validator ID.
skale node signature <VALIDATOR_ID>Arguments:
VALIDATOR_ID- The ID of the validator requesting the signature.
Prefix:
skale wallet
Commands related to the Ethereum wallet associated with the standard SKALE node.
skale wallet info [-f json/text]Options:
-f/--format json/text- optional.
Set the local wallet private key for the node.
skale wallet set --private-key $ETH_PRIVATE_KEYSend ETH from the node's wallet.
skale wallet send <RECEIVER_ADDRESS> <AMOUNT_ETH> [--yes]Arguments:
RECEIVER_ADDRESS- Ethereum receiver address.AMOUNT_ETH- Amount of ETH tokens to send.
Optional arguments:
--yes- Send without additional confirmation.
Prefix:
skale schains
Commands for interacting with sChains managed by the standard node.
List of SKALE Chains served by connected node.
skale schains lsShow the configuration for a specific SKALE Chain.
skale schains config <SCHAIN_NAME>List DKG status for each SKALE Chain on the node.
skale schains dkgShow information about a specific SKALE Chain on the node.
skale schains info <SCHAIN_NAME> [--json]Options:
--json- Show info in JSON format.
Turn on repair mode for a specific SKALE Chain.
skale schains repair <SCHAIN_NAME>Prefix:
skale health
Commands to check the health of the standard node and its components.
List all SKALE containers running on the connected node.
skale health containers [-a/--all]Options:
-a/--all- list all containers (by default - only running).
Show health check results for all SKALE Chains on the node.
skale health schains [--json]Options:
--json- Show data in JSON format.
Status of the SGX server. Returns the SGX server URL and connection status.
skale health sgxPrefix:
skale ssl
Manage SSL certificates for the standard node.
Status of the SSL certificates on the node.
skale ssl statusAdmin API URL: [GET] /api/ssl/status
Upload new SSL certificates.
skale ssl upload -c <CERT_PATH> -k <KEY_PATH> [-f/--force]Options:
-c/--cert-path- Path to the certificate file.-k/--key-path- Path to the key file.-f/--force- Overwrite existing certificates.
Admin API URL: [POST] /api/ssl/upload
Check SSL certificate by connecting to the health-check SSL server.
skale ssl check [-c <CERT_PATH>] [-k <KEY_PATH>] [--type <TYPE>] [--port <PORT>] [--no-client]Options:
-c/--cert-path- Path to the certificate file (default: uploaded usingskale ssl uploadcertificate).-k/--key-path- Path to the key file (default: uploaded usingskale ssl uploadkey).--type/-t- Check type (openssl- openssl cli check,skaled- skaled-based check,all- both).--port/-p- Port to start healthcheck server (default:4536).--no-client- Skip client connection (only make sure server started without errors).
Prefix:
skale logs
Access logs for the standard node.
Fetch node CLI logs:
skale logs cli [--debug]Options:
--debug- show debug logs; more detailed output.
Dump all logs from the connected node:
skale logs dump [TARGET_PATH] [-c/--container <CONTAINER_NAME>]Arguments:
TARGET_PATH- Optional path to save the log dump archive.
Options:
--container,-c- Dump logs only from specified container.
Commands available in the passive skale binary for managing dedicated Passive nodes.
Note that this binary contains a different set of commands compared to the standard build.
Print build info for the skale (passive) binary.
skale infoPrint version number for the skale (passive) binary.
skale versionOptions:
--short- prints version only, without additional text.
Prefix:
skale passive-node
Initialize a dedicated Passive node on the current machine.
skale passive-node init [ENV_FILE] [--indexer | --archive] [--snapshot] [--snapshot-from <IP>] [--yes]Arguments:
ENV_FILE- path to .env file (required).
Required environment variables in ENV_FILE:
BLOCK_DEVICE- Absolute path to a dedicated raw block device (e.g. /dev/sdc).DOCKER_LVMPY_VERSION- Version ofdocker-lvmpy.NODE_VERSION- Version ofskale-node.ENDPOINT- RPC endpoint of the network where SKALE Manager is deployed.MANAGER_CONTRACTS- SKALE Manager alias or address.IMA_CONTRACTS- IMA alias or address.SCHAIN_NAME- Name of the specific SKALE chain to sync.ENV_TYPE- Environment type (e.g., 'mainnet', 'testnet').
In
MANAGER_CONTRACTSandIMA_CONTRACTSfields, if you are using a recognized network (e.g., 'Mainnet', 'Holesky', 'local'), you can use a recognized alias (e.g., 'production', 'grants'). You can check the list of recognized networks and aliases in contract deployments. :warning: If you are using a custom network or a contract which isn't recognized by the underlyingskale-contractslibrary, you MUST provide a direct contract address.
Options:
--indexer- Run in indexer mode (disables block rotation).--archive- Run in archive mode (enable historic state and disable block rotation).--snapshot- Start sync node from snapshot.--snapshot-from <IP>- Specify the IP of another node to download a snapshot from.--yes- Initialize without additional confirmation.
Update the Passive node software and configuration.
skale passive-node update [ENV_FILEPATH] [--yes]Arguments:
ENV_FILEPATH- Path to the .env file.
Options:
--yes- Update without additionalconfirmation.
NOTE: You can just update a file with environment variables used during
skale passive-node init.
Remove all data and containers for the Passive node.
skale passive-node cleanup [--yes]Options:
--yes- Cleanup without confirmation.
WARNING: This command removes all Passive node data.
Commands available in the fair binary for managing nodes on the Fair network.
Print build info for the fair binary.
fair infoPrint version number for the fair binary.
fair version [--short]Options:
--short- prints version only, without additional text.
Prefix:
fair boot
Commands for a Fair node in the Boot phase.
Get information about the Fair node during boot phase.
fair boot info [--format FORMAT]Options:
--format/-f- Output format (jsonortext).
Initialize the Fair node boot phase.
fair boot init <ENV_FILE>Arguments:
ENV_FILE- Path to the environment file containing configuration.
Required environment variables in ENV_FILE:
SGX_SERVER_URL- SGX server URL.BLOCK_DEVICE- Absolute path to a dedicated raw block device (e.g. /dev/sdc).NODE_VERSION- Version ofskale-node.ENDPOINT- RPC endpoint of the network where Fair Manager is deployed.MANAGER_CONTRACTS- SKALE Manager alias or address.IMA_CONTRACTS- IMA alias or address (Note: Required by boot service, may not be used by Fair itself).FILEBEAT_HOST- URL/IP:Port of the Filebeat log server.ENV_TYPE- Environment type (e.g., 'mainnet', 'devnet').
Optional variables:
MONITORING_CONTAINERS- Enable monitoring containers (cadvisor,node-exporter).
Register the Fair node with Fair Manager during the boot phase.
fair boot register --name <NODE_NAME> --ip <PUBLIC_IP> --domain <DOMAIN_NAME> [--port <BASE_PORT>]Options:
--name/-n- Fair node name (required).--ip- Public IP for RPC connections & consensus (required).--domain/-d- Fair node domain name (e.g.,fair1.example.com, required).--port/-p- Base port for node sChains (default: from configuration).
Get the node signature for a validator ID during boot phase.
fair boot signature <VALIDATOR_ID>Arguments:
VALIDATOR_ID- The ID of the validator requesting the signature.
Update the Fair node software during boot phase.
fair boot update <ENV_FILE> [--yes] [--pull-config SCHAIN]Arguments:
ENV_FILE- Path to the environment file for node configuration.
Required environment variables in ENV_FILE:
SGX_SERVER_URL- SGX server URL.BLOCK_DEVICE- Absolute path to a dedicated raw block device (e.g. /dev/sdc).NODE_VERSION- Version ofskale-node.ENDPOINT- RPC endpoint of the network where Fair Manager is deployed.MANAGER_CONTRACTS- SKALE Manager alias or address.IMA_CONTRACTS- IMA alias or address (Note: Required by boot service, may not be used by Fair itself).FILEBEAT_HOST- URL/IP:Port of the Filebeat log server.ENV_TYPE- Environment type (e.g., 'mainnet', 'devnet').
Optional variables:
MONITORING_CONTAINERS- Enable monitoring containers (cadvisor,node-exporter).
Options:
--yes- Update without confirmation prompt.--pull-config- Pull configuration for specific sChain (hidden option).
Prefix:
fair node
Commands for managing a Fair node during its regular operation (main phase).
Get information about the Fair node.
fair node info [--format FORMAT]Options:
--format/-f- Output format (jsonortext).
Initialize the regular operation phase of the Fair node.
fair node init <ENV_FILEPATH>Arguments:
ENV_FILEPATH- Path to the environment file for node configuration.
Required environment variables in ENV_FILEPATH:
FAIR_CONTRACTS- Fair contracts alias or address (e.g.,mainnet).NODE_VERSION- Version ofskale-node.BOOT_ENDPOINT- RPC endpoint of the Fair network (e.g.,https://rpc.fair.cloud/).SGX_SERVER_URL- SGX server URL (e.g.,https://127.0.0.1:1026/).BLOCK_DEVICE- Absolute path to a dedicated raw block device (e.g.,/dev/sdc).ENV_TYPE- Environment type (e.g.,mainnet).
Optional variables:
ENFORCE_BTRFS- Format existing filesystem on attached disk (True/False).FILEBEAT_HOST- URL of the Filebeat log server to send logs.
Register the Fair node with the specified IP address.
fair node register --ip <IP_ADDRESS>Options:
--ip- Public IP address for the Fair node (required).
Update the Fair node software.
fair node update <ENV_FILEPATH> [--yes] [--force-skaled-start]Arguments:
ENV_FILEPATH- Path to the environment file for node configuration.
Required environment variables in ENV_FILEPATH:
FAIR_CONTRACTS- Fair contracts alias or address (e.g.,mainnet).NODE_VERSION- Version ofskale-node.BOOT_ENDPOINT- RPC endpoint of the Fair network (e.g.,https://rpc.fair.cloud/).SGX_SERVER_URL- SGX server URL (e.g.,https://127.0.0.1:1026/).BLOCK_DEVICE- Absolute path to a dedicated raw block device (e.g.,/dev/sdc).ENV_TYPE- Environment type (e.g.,mainnet).
Optional variables:
ENFORCE_BTRFS- Format existing filesystem on attached disk (True/False).FILEBEAT_HOST- URL of the Filebeat log server to send logs.
Options:
--yes- Update without confirmation prompt.--force-skaled-start- Force skaled container to start (hidden option).
Turn off the Fair node containers.
fair node turn-off [--yes]Options:
--yes- Turn off without confirmation.
Turn on the Fair node containers.
fair node turn-on [ENV_FILEPATH] [--yes]Arguments:
ENV_FILEPATH- Path to the .env file.
Options:
--yes- Turn on without additional confirmation.
Switch from boot phase to regular Fair node operation.
fair node migrate <ENV_FILEPATH> [--yes]Arguments:
ENV_FILEPATH- Path to the environment file for node configuration.
Required environment variables in ENV_FILEPATH:
FAIR_CONTRACTS- Fair contracts alias or address (e.g.,mainnet).NODE_VERSION- Version ofskale-node.BOOT_ENDPOINT- RPC endpoint of the Fair network (e.g.,https://rpc.fair.cloud/).SGX_SERVER_URL- SGX server URL (e.g.,https://127.0.0.1:1026/).BLOCK_DEVICE- Absolute path to a dedicated raw block device (e.g.,/dev/sdc).ENV_TYPE- Environment type (e.g.,mainnet).
Optional variables:
ENFORCE_BTRFS- Format existing filesystem on attached disk (True/False).FILEBEAT_HOST- URL of the Filebeat log server to send logs.
Options:
--yes- Migrate without confirmation prompt.
Toggle fair chain repair mode.
fair node repair [--snapshot-from SOURCE] [--yes]Options:
--snapshot-from- Source for snapshots (anyby default, hidden option).--yes- Proceed without confirmation prompt.
Generate a backup archive of the Fair node's state.
fair node backup <BACKUP_FOLDER_PATH>Arguments:
BACKUP_FOLDER_PATH- Path to the folder where the backup file will be saved.
Restore a Fair node from a backup archive.
fair node restore <BACKUP_PATH> <ENV_FILE> [--config-only]Arguments:
BACKUP_PATH- Path to the backup archive.ENV_FILE- Path to the .env file for the restored node configuration.
Options:
--config-only- Only restore configuration files.
Cleanup Fair node data and configuration.
fair node cleanup [--yes]Options:
--yes- Cleanup without confirmation prompt.
Change the IP address of the Fair node.
fair node change-ip <IP_ADDRESS>Arguments:
IP_ADDRESS- New public IP address for the Fair node.
Prefix:
fair chain
Commands for managing and monitoring the Fair chain state and configuration.
Get information about the Fair chain record, including chain name, configuration status, DKG status, and operational metadata.
fair chain record [--json]Options:
--json- Output in JSON format instead of formatted table.
Get the status of Fair chain checks, including configuration checks and skaled checks.
fair chain checks [--json]Options:
--json- Output in JSON format instead of formatted table.
Prefix:
fair wallet
Commands for managing the node wallet.
Get information about the SKALE node wallet.
fair wallet info [--format FORMAT]Options:
--format/-f- Output format (jsonortext).
Send ETH from SKALE node wallet to an address.
fair wallet send <ADDRESS> <AMOUNT> [--yes]Arguments:
ADDRESS- Destination address for ETH transfer.AMOUNT- Amount of ETH to send (as float).
Options:
--yes- Send without confirmation prompt.
Prefix:
fair logs
Commands for managing and accessing node logs.
Fetch the logs of the node-cli.
fair logs cli [--debug]Options:
--debug- Show debug logs instead of regular logs.
Dump all logs from the connected node.
fair logs dump <PATH> [--container CONTAINER]Arguments:
PATH- Path where the logs dump will be saved.
Options:
--container/-c- Dump logs only from specified container.
Prefix:
fair ssl
Commands for managing SSL certificates for sChains.
Check the status of SSL certificates on the node.
fair ssl statusUpload SSL certificate files to the node.
fair ssl upload --cert-path <CERT_PATH> --key-path <KEY_PATH> [--force]Options:
--cert-path/-c- Path to the SSL certificate file (required).--key-path/-k- Path to the SSL private key file (required).--force/-f- Overwrite existing certificates.
Check SSL certificate validity and connectivity.
fair ssl check [--cert-path CERT_PATH] [--key-path KEY_PATH] [--port PORT] [--type TYPE] [--no-client] [--no-wss]Options:
--cert-path/-c- Path to the certificate file (default: system default).--key-path/-k- Path to the key file (default: system default).--port/-p- Port to start SSL health check server (default: from configuration).--type/-t- Check type:all,openssl, orskaled(default:all).--no-client- Skip client connection for openssl check.--no-wss- Skip WSS server starting for skaled check.
Prefix:
fair staking
Commands for interacting with the Fair staking functionality.
Allow an address to receive staking fees.
fair staking add-receiver <RECEIVER_ADDRESS>Arguments:
RECEIVER_ADDRESS- Address to add to the allowed receivers list.
Remove an address from the allowed receivers list.
fair staking remove-receiver <RECEIVER_ADDRESS>Arguments:
RECEIVER_ADDRESS- Address to remove from the allowed receivers list.
Workflow (fees): request fees -> review exit requests -> claim request.
Create a request to claim a specific amount of earned fees (FAIR). Use --all to request all.
fair staking request-fees <AMOUNT>
fair staking request-fees --allCreate a request to send a specific amount (or all) of earned fees to an address.
fair staking request-send-fees <TO_ADDRESS> <AMOUNT>
fair staking request-send-fees <TO_ADDRESS> --allArguments:
TO_ADDRESS- Destination address for the fee transfer.AMOUNT- Amount of fees to include in the request (FAIR).
Claim a previously created request by its request ID once it is unlocked.
fair staking claim-request <REQUEST_ID>List exit (fee withdrawal) requests for the current wallet. Use --json for raw JSON output.
fair staking exit-requests
fair staking exit-requests --jsonDefault output (non-JSON) shows: request_id, user, node_id, amount_wei, amount_fair, unlock_date (ISO).
Get the currently earned (unrequested) fee amount.
fair staking earned-fee-amountSet the fee rate (uint16 value) used by the staking logic.
fair staking set-fee-rate <FEE_RATE>Arguments:
FEE_RATE- Fee rate value as integer (uint16).
Prefix:
fair passive-node(passive Fair build)
Commands for operating a passive Fair node (sync/indexer/archive).
Initialize a passive Fair node.
fair passive-node init <ENV_FILEPATH> --id <NODE_ID> [--indexer | --archive] [--snapshot <URL|any>]Arguments:
ENV_FILEPATH- Path to the environment file with configuration.
Required environment variables in ENV_FILEPATH:
FAIR_CONTRACTS- Fair Manager contracts alias or address.NODE_VERSION- Version ofskale-node.BOOT_ENDPOINT- RPC endpoint of Fair network.BLOCK_DEVICE- Absolute path to a dedicated raw block device (e.g.,/dev/sdc).ENV_TYPE- Environment type (e.g.,mainnet,devnet).
Options:
--id- Numerical node identifier (required).--indexer- Run in indexer mode (no block rotation).--archive- Run in archive mode (historical state kept; disables block rotation). Mutually exclusive with--indexer.--snapshot <URL|any>- Start from provided snapshot URL or from any available source (not allowed together with--indexeror--archive).
By default runs a regular sync node.
Update software / configs for passive Fair node.
fair passive-node update <ENV_FILEPATH> [--yes]Turn off the Fair passive node containers.
fair passive-node turn-off [--yes]Options:
--yes- Turn off without confirmation.
Turn on the Fair passive node containers.
fair passive-node turn-on [ENV_FILEPATH] [--yes]Arguments:
ENV_FILEPATH- Path to the .env file.
Options:
--yes- Turn on without additional confirmation.
Remove all passive Fair node data and containers.
fair passive-node cleanup [--yes]Options:
--yes- Proceed without confirmation.
Exit codes conventions for SKALE CLI tools
0- Everything is OK1- General error exit code3- Bad API response**4- Script execution error**5- Transaction error*6- Revert error*7- Bad user error**8- Node state error**
* - validator-cli only
** - node-cli only
- Python 3.11
- Git
Clone with HTTPS:
git clone https://github.com/skalenetwork/node-cli.gitOr with SSH:
git clone git@github.com:skalenetwork/node-cli.gitpython3.11 -m venv venv
source venv/bin/activatepip install -e ".[dev]"Specify the build type (normal, passive, or fair):
# Example for Standard build
./scripts/generate_info.sh 1.0.0 my-branch normal
# Example for Passive build
./scripts/generate_info.sh 1.0.0 my-branch passive
# Example for Fair build
./scripts/generate_info.sh 1.0.0 my-branch fairIn file .git/hooks/pre-commit add:
#!/bin/sh
./venv/bin/ruff check .Note: This hook assumes your virtual environment is named 'venv' and is located at the root of the repository.
Make the hook executable:
chmod +x .git/hooks/pre-commitIf you have any questions please ask our development community on Discord.
Copyright (C) 2018-present SKALE Labs