Skip to content

env: drop LUX_ prefix from env vars (noise)#38

Merged
hanzo-dev merged 1 commit into
mainfrom
env/drop-lux-prefix
May 15, 2026
Merged

env: drop LUX_ prefix from env vars (noise)#38
hanzo-dev merged 1 commit into
mainfrom
env/drop-lux-prefix

Conversation

@hanzo-dev
Copy link
Copy Markdown
Member

Summary

Drop LUX_ prefix from env vars across cli — the brand prefix was noise:

  • LUX_MNEMONIC -> MNEMONIC (deploy script + LLM doc)
  • LUX_PRIVATE_KEY -> PRIVATE_KEY (deploy script + LLM doc)
  • LUX_INSECURE_TLS -> INSECURE_TLS
  • LUX_NODE_ENDPOINT -> NODE_ENDPOINT
  • LUX_NETWORK_TYPE -> NETWORK_TYPE (backend gRPC server selector)
  • LUX_RPC_URL -> RPC_URL
  • LUX_NODE_ROOT -> NODE_ROOT
  • LUX_CHART_PATH -> CHART_PATH
  • LUX_CHAINS_FILE -> CHAINS_FILE
  • LUX_KMS_ROOT_KEY -> KMS_ROOT_KEY
  • LUX_WC_PROJECT_ID -> WC_PROJECT_ID (WalletConnect)
  • LUX_BLS_KEY -> BLS_KEY
  • LUX_KEY_INDEX -> KEY_INDEX

pkg/key/backend_env.go: removed the LUX_-prefix-stripping getEnv()
helper (now reads env vars by exact name) and cleaned up the broken
"MNEMONIC / MNEMONIC" / "PRIVATE_KEY / PRIVATE_KEY" doc comments
which were a previous incomplete rename.

Out of scope (separate PR — requires luxfi/constants bump)

LUX_NODE_PATH, LUX_NETRUNNER_PATH, LUX_EVM_PATH,
LUX_PLUGINS_DIR are defined in upstream luxfi/constants package
(repos.go). Doc comments referencing them by name are left intact
because they describe the upstream-defined env var names accurately.

Out of scope (script-local variables, not env vars)

  • LUX_ZONE in scripts/update-cloudflare-dns.sh — Cloudflare DNS zone ID
  • LUX_BIN_DIR in scripts/install.sh~/.lux/bin path constant

Test plan

  • go build ./... clean
  • go test ./pkg/key/... passes (6.78s)
  • go test ./cmd/nodecmd/ -run TestDefaultChartPath passes
    (validates new CHART_PATH env handling)

Breaking change

Per CLAUDE.md no-backwards-compatibility rule, the old LUX_X
forms are removed. Callers/operators must update env var names.

Renames LUX_-prefixed env vars to canonical, non-noisy forms:

- LUX_MNEMONIC      -> MNEMONIC      (deploy script + LLM doc)
- LUX_PRIVATE_KEY   -> PRIVATE_KEY   (deploy script + LLM doc)
- LUX_INSECURE_TLS  -> INSECURE_TLS
- LUX_NODE_ENDPOINT -> NODE_ENDPOINT
- LUX_NETWORK_TYPE  -> NETWORK_TYPE  (backend gRPC server selector)
- LUX_RPC_URL       -> RPC_URL
- LUX_NODE_ROOT     -> NODE_ROOT
- LUX_CHART_PATH    -> CHART_PATH
- LUX_CHAINS_FILE   -> CHAINS_FILE
- LUX_KMS_ROOT_KEY  -> KMS_ROOT_KEY
- LUX_WC_PROJECT_ID -> WC_PROJECT_ID (WalletConnect)
- LUX_BLS_KEY       -> BLS_KEY       (was already supported via getEnv())
- LUX_KEY_INDEX     -> KEY_INDEX     (was already supported via getEnv())

pkg/key/backend_env.go: removed the LUX_-prefix-stripping getEnv()
helper (now reads env vars by exact name) and dropped the broken
"MNEMONIC / MNEMONIC" / "PRIVATE_KEY / PRIVATE_KEY" doc comments
which were a previous incomplete rename.

NOT renamed (defined in upstream luxfi/constants — separate concern):
- LUX_NODE_PATH      (constants.EnvNodePath)
- LUX_NETRUNNER_PATH (constants.EnvNetrunnerPath)
- LUX_EVM_PATH       (constants.EnvEVMPath)
- LUX_PLUGINS_DIR    (constants.EnvPluginsDir)

Doc comments referencing those env vars (cmd/root.go,
cmd/networkcmd/start.go, cmd/nodecmd/link.go) describe the
constants-defined names accurately and are left alone.

NOT renamed (script-local variables, not env vars):
- LUX_ZONE in scripts/update-cloudflare-dns.sh (Cloudflare DNS zone ID)
- LUX_BIN_DIR in scripts/install.sh (~/.lux/bin path constant)

BREAKING: external callers/operators must update env var names. Per
CLAUDE.md no-backwards-compatibility rule, the old forms are removed.
@hanzo-dev hanzo-dev merged commit ae0527c into main May 15, 2026
2 of 15 checks passed
@hanzo-dev hanzo-dev deleted the env/drop-lux-prefix branch May 15, 2026 23:35
hanzo-dev added a commit that referenced this pull request May 16, 2026
…39)

Picks up luxfi/constants@v1.5.4 which renames the 4 binary-path env var
values: LUX_NODE_PATH -> NODE_PATH, LUX_NETRUNNER_PATH -> NETRUNNER_PATH,
LUX_EVM_PATH -> EVM_PATH, LUX_PLUGINS_DIR -> PLUGINS_DIR.

Constant identifiers (EnvNodePath etc) unchanged — only doc strings in
root.go / networkcmd/start.go / nodecmd/link.go need a textual refresh.

BREAKING: external operators / scripts setting LUX_NODE_PATH (etc.) must
rename to the un-prefixed form. Completes the LUX_ prefix sweep started
in #38 — the 4 constants-defined names were left for this follow-up.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant