Skip to main content

AFS_AETHER_DISABLE

Deep-dive reference for:

  • AFS_AETHER_DISABLE

Status

  • active

Audience

  • production/user

Type and Default

  • Type: boolean.
  • Default: false (unset).

Accepted truthy values:

  • true, 1, yes, y, on

Accepted falsey values:

  • false, 0, no, n, off

What It Does

When enabled, Aether skips mount initialization and exits early from the mount path.

This is a rollout/rollback guard so wrappers can keep invoking Aether while forcing the runtime path off.

Input Surfaces

  • Env: AFS_AETHER_DISABLE=true
  • Config file (aether.toml): disable = true
  • CLI helper command:
    • aether fallback enable writes disable = true
    • aether fallback disable writes disable = false

There is no direct aether mount --disable flag.

Resolution and Override Order

  1. Built-in default (false)
  2. aether.toml (disable)
  3. Env (AFS_AETHER_DISABLE)
  4. Internal override layer (ConfigOverrides.disable) when set by a caller

For normal CLI usage, this is effectively:

  • config file + env (with env taking precedence).

Runtime Behavior

  • On aether mount, if resolved disable=true:
    • logs that runtime is disabled,
    • returns Error::Disabled,
    • top-level CLI exits with code 0 and prints the disabled message.
  • Non-mount commands (status/debug/cache/journal/config/fallback/metrics/etc.) are still available.

Error/Exit Semantics

  • Invalid boolean values fail config load (invalid value for AFS_AETHER_DISABLE).
  • In library error mapping, Error::Disabled maps to ENODEV.

Operational Guidance

  • Use for immediate client-side kill switch during incidents or staged rollout pauses.
  • Prefer config-file toggling (aether fallback enable|disable) for persistent behavior.
  • Prefer env override for one-shot/session-scoped suppression.

Quick Examples

  • One-shot disable via env:
    • AFS_AETHER_DISABLE=true aether mount --session-id s1 --mount-dir /mnt/s1
  • Persist disable in config:
    • aether fallback enable
  • Re-enable runtime:
    • aether fallback disable

Primary Implementation Sources

  • packages/aether/src/config/env/env_keys.rs
  • packages/aether/src/config/types/apply_env.rs
  • packages/aether/src/config/types/file_config_loader.rs
  • packages/aether-cli/src/app/dispatch_and_runtime.rs
  • packages/aether-cli/src/cli/commands/fallback.rs
  • packages/aether-cli/src/app/report_rendering.rs
  • packages/aether/src/lib.rs