ha-federated-access

ha-federated-access

Part of the Crooked Sentry universe Validate Codecov test coverage

Overview

Infrastructure tooling for federated Home Assistant access.

This repository packages auth and remote-access tooling for Home Assistant deployments. It is not a HACS package and not a Home Assistant integration. It is a host-level orchestration repo for installing and converging:

Current State

This extraction initially preserves the known-working implementation shape with minimal repackaging. The current focus is removing project-specific names, domains, paths, and assumptions while keeping behavior testable.

Do not treat this as a clean public install surface yet.

Repo Layout

ha-federated-access/
  .github/workflows/validate.yml
  docs/
  examples/
    config.example.yaml
    env.example
  homeassistant/
    auth_oidc/static/
      injection.js
      ha-branding-overrides.js
  netbird/
    docker-compose.yaml
    templates/
  patches/
    hass-oidc-auth-subject-link.patch
  scripts/
  terraform/
    cloudflare-dns/

Local Bootstrap

Copy the examples before running scripts on a target host:

cp examples/env.example .env
cp examples/config.example.yaml config.yaml

Then edit .env and config.yaml for the target environment.

Configuration Contract

examples/config.example.yaml is the supported config shape for this repo.

Required keys:

Compatibility:

Validation

The validation workflow checks:

Equivalent local commands:

bash -n scripts/*.sh scripts/lib/*.sh netbird/*.sh
python3 -m py_compile scripts/*.py
node --check homeassistant/auth_oidc/static/injection.js
node --check homeassistant/auth_oidc/static/ha-branding-overrides.js

Extraction Plan

  1. Preserve the known-working implementation in this standalone repo.
  2. Replace deployment-specific defaults with generic config/env inputs.
  3. Add focused tests for config rendering and patch application.
  4. Run one real converge from this repo against the existing Pi.
  5. Replace monorepo copies with wrappers or a vendored sync path after the standalone repo proves itself.

See docs/MIGRATION-FROM-MONOREPO.md for the temporary copied-file strategy and the planned release-tarball consumption model.