diff --git a/30-runbooks/local-auth-testing.md b/30-runbooks/local-auth-testing.md index 5e076e7..22ab069 100644 --- a/30-runbooks/local-auth-testing.md +++ b/30-runbooks/local-auth-testing.md @@ -1,7 +1,7 @@ --- owner: gmikcon status: active -last_reviewed: 2026-11-19 +last_reviewed: 2026-11-20 review_interval: 90d confidence: high source_of_truth: local-auth-setup @@ -9,6 +9,11 @@ # Local gnexus-auth testing +**Local development only.** This runbook describes the local gnexus-auth instance used +for development. The gnbook deployment currently points at this local instance as a +pre-production stopgap; it is not production authentication. Do not assign book +ownership to a local test identity. + How the local Gnexus Book instance is connected to the local gnexus-auth, which runs the same code as production. @@ -45,7 +50,8 @@ - Slug: `gnexus-book-local` (owner-provided local client); access mode: `all_active_users`. -- Default role: `user`; the test user is explicitly assigned the `editor` client role. +- Default role: `user`; the local test identity is explicitly assigned the `editor` + client role. - The client currently defines roles `editor`, `user`, `docs.write` and `inventory.write`, but no client permissions. Gnexus Book mirrors the roles snapshot and does not depend on client permissions for authorization yet. @@ -60,13 +66,12 @@ owner-registered client, HTTPS redirect/webhook URLs, a narrower access mode and properly defined permissions. -## Test user +## Test identity -A dedicated local user exists for end-to-end tests: +A local test identity exists for end-to-end tests. Its login, credentials and helper +files stay outside the repository (`~/.config/gnexus-book/`, `chmod 600`). It is not +the production owner and must not own production data. -- Login: `gnexus-book-test@local.test`. -- Credentials: `~/.config/gnexus-book/local-auth-test-user.txt` (`chmod 600`, outside - the repository). - Role: `editor` on the `gnexus-book-local` client; client permissions are currently empty, so `/me` reports `roles: ["editor"]` and `permissions: []`. @@ -103,6 +108,8 @@ ## Production differences +- Production authentication and the real owner `sub` are still pending; the local + client and local test identity are not production credentials. - Register the client in production gnexus-auth and use HTTPS redirect and webhook URLs. - Use `specific_users` or groups instead of `all_active_users`.