Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
c732827
ci: check the version bump with validate-bumpversion directly
benjamsf Nov 25, 2026
73c4dd5
refactor(agent): make murmur-agent a package
benjamsf Nov 26, 2026
936ed6e
refactor(api): split api.py into one module per router, as matrix and…
benjamsf Nov 26, 2026
666535b
feat(store): keep the state in Postgres with SQLModel
benjamsf Nov 26, 2026
7da6fd6
feat(store): copy the SQLite store of earlier releases once
benjamsf Nov 25, 2026
cbc8e5e
refactor: read settings with pydantic-settings, as rmapi and rmmtxaut…
benjamsf Nov 26, 2026
7d4d932
refactor: drop checks for states that cannot happen and comments that…
benjamsf Nov 26, 2026
7149149
feat(api): link the voice guide in the v2 description
benjamsf Nov 26, 2026
5727a38
test(ui): run the UI tests with vitest and Testing Library
benjamsf Nov 26, 2026
44cf69a
refactor(ui): split the admin view and the talk panel into components…
benjamsf Nov 26, 2026
6fc84de
refactor(ui): draw the icons with lucide-react
benjamsf Nov 25, 2026
d249d46
refactor(ui): build the controls on shadcn/ui
benjamsf Nov 26, 2026
2f0c1ac
test(ui): cover the admin view, the More menu and the member picker
benjamsf Nov 26, 2026
38b5dc3
feat(ui): pick the net from a compact select
benjamsf Nov 26, 2026
0df0a0a
feat(ui): add a voice guide behind a help button
benjamsf Nov 26, 2026
ceb30a2
feat(ui): scroll the open net's panel with the page
benjamsf Nov 25, 2026
784390a
refactor(ui): write the classes at their elements and delete ui.ts
benjamsf Nov 26, 2026
ef0e60d
refactor(ui): drop checks for states that cannot happen and comments …
benjamsf Nov 26, 2026
843bc0a
feat(ui): let the voice guide show the browser or ATAK, with pictures
benjamsf Nov 27, 2026
9160f1c
chore: bump version to 1.1.0+261125
benjamsf Nov 25, 2026
81ee353
refactor(store): drop the SQLite copy, keep Postgres only
benjamsf Nov 28, 2026
485209a
feat(agent): give each callsign at most four phone slots
benjamsf Nov 28, 2026
2dfcd91
docs: list the mTLS settings mumblermapi needs
benjamsf Nov 28, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .bumpversion.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tool.bumpversion]
current_version = "1.0.5+261119"
current_version = "1.1.0+261125"
parse = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)\\+(?P<build>\\d+)"
serialize = ["{major}.{minor}.{patch}+{build}"]
search = "{current_version}"
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ permissions:
contents: read

jobs:
checks:
# The version bump only: prek runs below, where its hooks' Python, UI and tools are installed
uses: pvarki/config-ci-library/.github/workflows/general-check.yml@5a0c4ca0d9e53135ea5ed3427840641d4ccb6aa2 # v0.14.2+261026
with:
run-prek: false
bumpversion:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- uses: pvarki/config-ci-library/.github/actions/validate-bumpversion@5a0c4ca0d9e53135ea5ed3427840641d4ccb6aa2 # v0.14.2+261026

prek:
runs-on: ubuntu-latest
Expand All @@ -28,7 +28,7 @@ jobs:
- uses: j178/prek-action@4e14d07f9231acabce116ccfca13b13dd9755ece # v3.0.0

publish:
needs: [checks, prek]
needs: [bumpversion, prek]
runs-on: arc-runner-set
permissions:
contents: read
Expand Down
47 changes: 30 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@ One image, three parts:
- **`murmur-agent`** runs as a sidecar next to Murmur and talks to it over Ice on localhost. It:
- authenticates every connection by its TAK client certificate. The chain must lead to the platform CA,
the certificate must not be revoked (rmapi OCSP), and the callsign in the Mumble username must equal
the certificate CN.
the certificate CN. Murmur gives each username a session of its own, so a callsign gets at most four
phone slots `<callsign>---<slot>` (ODVoice takes one per ATAK install) beside its bare name and its nine
browser slots. A fifth is refused for the rest of the deployment, as a slot keeps its user id; a person
who needs more devices gets a new callsign.
- refuses and disconnects callsigns that are revoked or have voice turned off in mumblermapi
- keeps the channel tree in place:
- `Units/` from mumblermapi. Each net is open, invite-only (its members and those of invite-only nets
Expand All @@ -20,7 +23,7 @@ One image, three parts:
- reports who is connected where back to mumblermapi
- **`mumblermapi`** is the registered rmapi product, in its own pod. It:
- receives rmapi's user events
- keeps the `Units/` nets and their members in SQLite
- keeps users, the `Units/` nets and their members in Postgres
- reads TAK missions and their subscribers with a plain TAK user identity, obtained through rmapi's
product interop
- serves the agent's desired state, the admin API and the UI remote
Expand Down Expand Up @@ -64,11 +67,19 @@ kubelet probes it too and a restart mends none of what it finds. `healthy` and `
every 15 s and logs each change:

- `no ready Linkerd proxy in mumblermapi's pod (<cause>)`: rmapi, murmur-agent and browser tickets are refused
- `the database cannot be reached (<cause>)`: tickets, user events and admin changes fail
- `murmur-agent has not reported for <n> s` (or since mumblermapi started): Murmur or the agent is away or refused
- `the voice gateway is not ready (<cause>)`: browsers cannot talk

`<cause>` is the HTTP status that came back, or why none did: `name resolution failed`, `connection refused` or
`timed out` (after 2 s). A failed lookup points at the cluster, such as in-cluster DNS or the node, not at voice.
`timed out` (after 2 s). For the database it is the first line of the driver's error, or `timed out`. A failed
lookup points at the cluster, such as in-cluster DNS or the node, not at voice.

## Database

mumblermapi keeps its state in its own CloudNativePG cluster, `mumble-postgres`. It creates its tables at start
with SQLModel's `create_all`, as rmapi does. That only adds missing tables, so a change to an existing table needs a
migration of its own.

## Configuration

Expand All @@ -77,19 +88,21 @@ Like every Deploy App product, mumblermapi reads the product manifest the platfo
(`rasenmaeher.mtls.base_uri`), and its own name (`product.dns`), which is its TAK identity's CN. Without a
manifest the in-cluster defaults apply. The variables below override it.

| Variable | Used by | Meaning |
| -------------------------------------------------------------------------------------------------- | ----------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `MURMUR_ICE_SECRET` | agent | Murmur's Ice write secret (required) |
| `AGENT_STATE_URL` | agent | mumblermapi's `/api/v1/agent/state`; unset runs on `AGENT_CHANNELS_FILE` alone |
| `AGENT_PRESENCE_URL` | agent | mumblermapi's `/api/v1/agent/presence`; unset reports nothing |
| `AGENT_CA_BUNDLE`, `AGENT_DATA_DIR`, `AGENT_OCSP_URL`, `AGENT_POLL_SECONDS`, `AGENT_SWEEP_SECONDS` | agent | see `config.py` |
| `MUMBLERMAPI_DATABASE`, `MUMBLERMAPI_TEMPLATES_DIR`, `MUMBLERMAPI_UI_DIR` | mumblermapi | SQLite file, channel plan templates admins may apply (`*.yaml`: `name`, `description`, `channels`, each channel with an optional `access` of `open`, `invite` or `inherit`; none is applied by default), built UI |
| `MUMBLERMAPI_RMAPI_IDENTITY`, `MUMBLERMAPI_AGENT_IDENTITY` | mumblermapi | Linkerd identities allowed to send user events and read agent state |
| `MUMBLERMAPI_TRAEFIK_IDENTITY`, `MUMBLERMAPI_CA_BUNDLE` | mumblermapi | The edge whose forwarded certificate voice tickets are minted for, and the CAs it must chain to |
| `AGENT_GATEWAY_CA` | agent | The voice gateway's CA; unset lets no browser in |
| `MUMBLERMAPI_PROXY_READY_URL`, `MUMBLERMAPI_GATEWAY_READY_URL` | mumblermapi | What the health check asks: this pod's Linkerd proxy, default `http://127.0.0.1:4191/ready`, and the voice gateway's `/readyz`; empty skips that check |
| `MUMBLERMAPI_TAK_URL`, `MUMBLERMAPI_TAK_SERVER_NAME`, `MUMBLERMAPI_TAK_CN` | mumblermapi | TAK's API, the name on TAK's certificate, our TAK identity's CN (default: the manifest's `product.dns`); unset leaves `Missions/` empty |
| `MUMBLERMAPI_RMAPI_URL` | mumblermapi | rmapi, for our TAK certificate and TAK rights (default: the manifest's `rasenmaeher.mtls.base_uri`) |
| Variable | Used by | Meaning |
| -------------------------------------------------------------------------------------------------- | ----------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `MTLS_TRUST_L5D`, `MTLS_REQUIRE_L5D`, `MTLS_TRUSTED_INGRESS_IDENTITIES` | mumblermapi | How libpvarki knows who calls the API. On opendefence-platform: `true`, `true` and Traefik's Linkerd identity. Unset, it trusts an `X-ClientCert-DN` header from anyone |
| `MURMUR_ICE_SECRET` | agent | Murmur's Ice write secret (required) |
| `AGENT_STATE_URL` | agent | mumblermapi's `/api/v1/agent/state`; unset runs on `AGENT_CHANNELS_FILE` alone |
| `AGENT_PRESENCE_URL` | agent | mumblermapi's `/api/v1/agent/presence`; unset reports nothing |
| `AGENT_CA_BUNDLE`, `AGENT_DATA_DIR`, `AGENT_OCSP_URL`, `AGENT_POLL_SECONDS`, `AGENT_SWEEP_SECONDS` | agent | see `agent/config.py` |
| `MUMBLERMAPI_DATABASE_HOST`, `_PORT`, `_NAME`, `_USER`, `_PASSWORD` | mumblermapi | mumblermapi's Postgres, from CloudNativePG's app secret (`host`, `port`, `dbname`, `username`, `password`); default `mumble-postgres-rw:5432`, database and user `mumble` |
| `MUMBLERMAPI_TEMPLATES_DIR`, `MUMBLERMAPI_UI_DIR` | mumblermapi | Channel plan templates admins may apply (`*.yaml`: `name`, `description`, `channels`, each channel with an optional `access` of `open`, `invite` or `inherit`; none is applied by default), built UI |
| `MUMBLERMAPI_RMAPI_IDENTITY`, `MUMBLERMAPI_AGENT_IDENTITY` | mumblermapi | Linkerd identities allowed to send user events and read agent state |
| `MUMBLERMAPI_TRAEFIK_IDENTITY`, `MUMBLERMAPI_CA_BUNDLE` | mumblermapi | The edge whose forwarded certificate voice tickets are minted for, and the CAs it must chain to |
| `AGENT_GATEWAY_CA` | agent | The voice gateway's CA; unset lets no browser in |
| `MUMBLERMAPI_PROXY_READY_URL`, `MUMBLERMAPI_GATEWAY_READY_URL` | mumblermapi | What the health check asks: this pod's Linkerd proxy, default `http://127.0.0.1:4191/ready`, and the voice gateway's `/readyz`; empty skips that check |
| `MUMBLERMAPI_TAK_URL`, `MUMBLERMAPI_TAK_SERVER_NAME`, `MUMBLERMAPI_TAK_CN` | mumblermapi | TAK's API, the name on TAK's certificate, our TAK identity's CN (default: the manifest's `product.dns`); unset leaves `Missions/` empty |
| `MUMBLERMAPI_RMAPI_URL` | mumblermapi | rmapi, for our TAK certificate and TAK rights (default: the manifest's `rasenmaeher.mtls.base_uri`) |

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MTLS_TRUST_L5D, MTLS_REQUIRE_L5D and MTLS_TRUSTED_INGRESS_IDENTITIES should also be mentioned as they are important to be used, especially on opendefence-platform.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added to the settings table.

Mission nets need takrmapi's `/api/v1/interop/add` and rmapi calling it without a double slash. Both are
upstream changes that `VOICE-PLAN.md` tracks.
Expand All @@ -98,7 +111,7 @@ upstream changes that `VOICE-PLAN.md` tracks.

```bash
uv sync
uv run pytest
uv run pytest # starts a Postgres in Docker (tests/docker-compose.yml)
uv run mypy src tests

pnpm -C ui install
Expand Down
11 changes: 10 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "mumblermapi"
version = "1.0.5+261119"
version = "1.1.0+261125"
description = "Murmur (Mumble server) integration for the OpenDefence platform"
license = { text = "GPL-2.0-only" }
readme = "README.md"
Expand All @@ -11,8 +11,11 @@ dependencies = [
"cryptography>=46.0",
"fastapi>=0.143,<1.0",
"libpvarki>=2.2,<3.0",
"psycopg2-binary>=2.9,<3.0",
"pydantic>=2.14,<3.0",
"pydantic-settings>=2.8,<3.0",
"pyyaml>=6.0,<7.0",
"sqlmodel>=0.0.37,<1.0",
"uvicorn>=0.30,<1.0",
]

Expand All @@ -27,6 +30,7 @@ dev = [
"pyrefly>=1.3,<2",
"pytest>=8.0,<9.0",
"pytest-cov>=6.0,<7.0",
"pytest-docker>=3.2,<4.0",
"types-pyyaml>=6.0,<7.0",
]

Expand Down Expand Up @@ -66,3 +70,8 @@ ignore_missing_imports = true
replace-imports-with-any = ["Ice", "MumbleServer"]
# The tests are a package of their own beside src
search-path = ["src", "."]

[[tool.pyrefly.sub-config]]
# Table classes name their table with a plain string where SQLModel declares a declared_attr
matches = "src/mumblermapi/store/tables.py"
errors = { bad-override = false }
2 changes: 1 addition & 1 deletion src/mumblermapi/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
"""Murmur integration for the OpenDefence platform"""

__version__ = "1.0.5+261119"
__version__ = "1.1.0+261125"
Loading