Skip to content

Electrs fails with Bitcoin Knots due to environment variable parsing error #12

@harbi

Description

@harbi

Bug Description:
Electrs app crashes with Error: Failed to resolve address 10.21.21.7:: invalid port value when using Bitcoin Knots instead of Bitcoin Core.

Root Cause:
The app expects Bitcoin Core environment variables APP_BITCOIN_* but Bitcoin Knots uses different variable names APP_BITCOIN_KNOTS_*. When APP_BITCOIN_RPC_PORT is undefined, it creates malformed address 10.21.21.7: instead of 10.21.21.7:8332.

Environment:

  • Umbrel Home (2024)
  • umbrelOS 1.4.2
  • Bitcoin Knots 29.1.knots20250903
  • Electrs v0.10.9-1

Steps to Reproduce:

  1. Install Bitcoin Knots on Umbrel
  2. Install Electrs app
  3. Start Electrs
  4. Check logs

Logs sample:

electrs_app_1        | Electrum attempting reconnect...
electrs_app_1        | Electrum attempting reconnect...
electrs_app_1        | Electrum attempting reconnect...
electrs_app_1        | Electrum attempting reconnect...
electrs_app_1        | Electrum attempting reconnect...
electrs_app_1        | Electrum attempting reconnect...
electrs_app_1        | Electrum attempting reconnect...
...
Error: Failed to resolve address 10.21.21.7:: invalid port value
Error: Failed to resolve address 10.21.21.7:: invalid port value
Error: Failed to resolve address 10.21.21.7:: invalid port value
Error: Failed to resolve address 10.21.21.7:: invalid port value
Error: Failed to resolve address 10.21.21.7:: invalid port value

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions