Calendar is a roster-mode app: its team recipe
Calendar's team mode (oficina/calendar #35, team-mode @ e8e509d, through
Home's teammode.ConfigFromEnv("CALENDAR") in cmd/calendar/main.go):
Roster true, the five CALENDAR_TEAM_* keys from teamKeys (the roster
token Home's bearer, fetched by replaying step 5), and
CALENDAR_ALLOWED_ADDRESSES no longer written: resolveAllowlist admits an
empty list beside team configuration. CALENDAR_DEK stays GENERATED;
CALENDAR_HOME_* and HOME_DIRECTORY_ORIGIN already matched. Step 11
verifies Calendar through /api/team (teammode.ProbePath, teammode.Probe).
TestRosterRecipes pins Calendar's exact names; every app but Calls is now
roster-mode, and the fake console serves /api/team for each of them; the
end-to-end run, the crash suite and homecompat (Home's real 0cee9ba
engine) activate Calendar, with Calls asserted still pending and its
allowlist still holding the owner. The README names the five roster
apps.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
6 files changed,
+33
−23
README.md+6 −6console/fakeconsole/fakeconsole.go+2 −2homecompat/compat_test.go+4 −1provision/apps.go+6 −2provision/apps_test.go+9 −6provision/review_test.go+6 −6
CI passed — run details
diff --git a/README.md b/README.md| index 6be404f..e84bb69 100644 |
| --- a/README.md |
| +++ b/README.md |
| @@ -128,12 +128,12 @@ recorded here instead (Fable's rulings on oficina/alta #1): |
| refuse parks there as `version-unacceptable` instead of failing |
| activation. |
| - **§6 step 11, `/api/team`**: the roster-mode apps are Docs, Sheets, |
| - Slides and Memoria (team mode on each app's main or team-mode branch: |
| - Docs `e58a22f`, Sheets #52, Slides #33, Memoria #32). Each serves the |
| - readiness probe once that build is deployed; until then it parks at |
| - `no-readiness-probe` (its directory row stays pending, and the owner's |
| - address is deleted all the same). Calendar and Calls have no roster |
| - mode yet and keep the owner allowlist. Memoria's AI stays off in team |
| + Slides, Calendar and Memoria (team mode on each app's main or team-mode |
| + branch: Docs `e58a22f`, Sheets #52, Slides #33, Calendar #35, Memoria |
| + #32). Each serves the readiness probe once that build is deployed; until |
| + then it parks at `no-readiness-probe` (its directory row stays pending, |
| + and the owner's address is deleted all the same). Calls has no roster |
| + mode yet and keeps the owner allowlist. Memoria's AI stays off in team |
| mode: no `MEMORIA_AI`, TensorX key, siblings or logged mail. |
| - **§11, Help**: the account menu has no Help items yet (no Colophon page). |
diff --git a/console/fakeconsole/fakeconsole.go b/console/fakeconsole/fakeconsole.go| index bdfcf50..cc59f17 100644 |
| --- a/console/fakeconsole/fakeconsole.go |
| +++ b/console/fakeconsole/fakeconsole.go |
| @@ -576,8 +576,8 @@ func (c *Console) Transport() http.RoundTripper { |
| } else { |
| rec.WriteString(i.serving) |
| } |
| - case r.URL.Path == "/api/team" && (i.app == "docs" || i.app == "sheets" || i.app == "slides" || i.app == "memoria") && !c.NoTeamProbe: |
| - // The roster-mode apps: Docs, Sheets, Slides and Memoria. |
| + case r.URL.Path == "/api/team" && i.app != "calls" && !c.NoTeamProbe: |
| + // The roster-mode apps: all but Calls. |
| p := strings.ToUpper(i.app) |
| b := c.envs[i.app][i.env] |
| _, token := b.vars[p+"_TEAM_ROSTER_TOKEN"] |
diff --git a/homecompat/compat_test.go b/homecompat/compat_test.go| index 2431d7e..a36611a 100644 |
| --- a/homecompat/compat_test.go |
| +++ b/homecompat/compat_test.go |
| @@ -382,9 +382,12 @@ func TestAltaAgainstHomesRealOperator(t *testing.T) { |
| if err := r.home.dirDB.QueryRow("SELECT state FROM team_instances WHERE consumer_id='lagged-memoria'").Scan(&state); err != nil || state != "live" { |
| t.Fatalf("memoria at the directory: %q %v", state, err) |
| } |
| - if err := r.home.dirDB.QueryRow("SELECT state FROM team_instances WHERE consumer_id='lagged-calendar'").Scan(&state); err != nil || state != "pending" { |
| + if err := r.home.dirDB.QueryRow("SELECT state FROM team_instances WHERE consumer_id='lagged-calendar'").Scan(&state); err != nil || state != "live" { |
| t.Fatalf("calendar at the directory: %q %v", state, err) |
| } |
| + if err := r.home.dirDB.QueryRow("SELECT state FROM team_instances WHERE consumer_id='lagged-calls'").Scan(&state); err != nil || state != "pending" { |
| + t.Fatalf("calls at the directory: %q %v", state, err) |
| + } |
| var n int |
| _ = r.home.credDB.QueryRow("SELECT count(*) FROM consumers WHERE state='active'").Scan(&n) |
| if n != 6 { |
diff --git a/provision/apps.go b/provision/apps.go| index e51a475..494486c 100644 |
| --- a/provision/apps.go |
| +++ b/provision/apps.go |
| @@ -46,7 +46,7 @@ var Apps = []App{ |
| {Slug: "docs", Name: "Docs", Prefix: "DOCS", Roster: true, MailPrefixes: []string{"DOCS_SMTP"}}, |
| {Slug: "sheets", Name: "Sheets", Prefix: "SHEETS", Roster: true, MailPrefixes: []string{"CARLOS_SMTP"}}, |
| {Slug: "slides", Name: "Slides", Prefix: "SLIDES", Roster: true, MailPrefixes: []string{"SLIDES_SMTP", "CARLOS_SMTP"}}, |
| - {Slug: "calendar", Name: "Calendar", Prefix: "CALENDAR", MailPrefixes: []string{"CALENDAR_SMTP", "CARLOS_SMTP"}}, |
| + {Slug: "calendar", Name: "Calendar", Prefix: "CALENDAR", Roster: true, MailPrefixes: []string{"CALENDAR_SMTP", "CARLOS_SMTP"}}, |
| {Slug: "calls", Name: "Calls", Prefix: "CALLS", MailPrefixes: []string{"CALLS_SMTP", "CARLOS_SMTP"}, Relay: true}, |
| {Slug: "memoria", Name: "Memoria", Prefix: "MEMORIA", Roster: true, MailPrefixes: []string{"CARLOS_SMTP"}}, |
| } |
| @@ -167,7 +167,11 @@ func Recipe(app App, in Inputs) []Key { |
| // SLIDES_TEAM_*, so the owner is not written. |
| keys = append(keys, teamKeys(p, in)...) |
| case "calendar": |
| - keys = append(keys, Key{Name: "CALENDAR_DEK", Class: Generated, Secret: true}, owner("CALENDAR_ALLOWED_ADDRESSES")) |
| + // Team mode (oficina/calendar #35, team-mode @ e8e509d, through |
| + // Home's teammode): CALENDAR_ALLOWED_ADDRESSES is optional beside |
| + // CALENDAR_TEAM_*, so the owner is not written. |
| + keys = append(keys, Key{Name: "CALENDAR_DEK", Class: Generated, Secret: true}) |
| + keys = append(keys, teamKeys(p, in)...) |
| case "calls": |
| keys = append(keys, |
| Key{Name: "CALLS_DEK", Class: Generated, Secret: true}, |
diff --git a/provision/apps_test.go b/provision/apps_test.go| index c8e1f96..22bb23c 100644 |
| --- a/provision/apps_test.go |
| +++ b/provision/apps_test.go |
| @@ -5,7 +5,9 @@ import ( |
| "testing" |
| ) |
| -// The recipes against each app's own config readers. Memoria follows |
| +// The recipes against each app's own config readers. Calendar follows |
| +// oficina/calendar team-mode @ e8e509d (teammode; CALENDAR_ALLOWED_ADDRESSES |
| +// optional beside it). Memoria follows |
| // oficina/memoria team-mode @ 88f6cec (teammode; MEMORIA_OWNERS optional |
| // beside it; MEMORIA_TEAM the first label of MEMORIA_ORIGIN). Slides follows |
| // oficina/slides team-mode @ 80fd3c9 (Home's teammode.EnvNames("SLIDES"); |
| @@ -16,10 +18,11 @@ import ( |
| func TestRosterRecipes(t *testing.T) { |
| in := Inputs{Label: "lagged", Owner: "o@x.test", TeamSQID: "Uk", Record: []byte("{}"), Home: HomeConfig{Issuer: "https://id.oficina.works", Directory: "https://oficina.works", Provisioner: "AQ"}} |
| want := map[string][]string{ |
| - "docs": {"DOCS_ALLOWED_ADDRESSES", "DOCS_CONTENT_KEY", "DOCS_HOME_CONSUMER_ID", "DOCS_HOME_DEK_BASE64", "DOCS_HOME_ISSUER", "DOCS_HOME_KEYS_BASE64", "DOCS_INSTANCE_KEY", "DOCS_ORIGIN", "DOCS_TEAM_DIRECTORY_ORIGIN", "DOCS_TEAM_ID", "DOCS_TEAM_OPERATOR_KEYS_BASE64", "DOCS_TEAM_PROVISIONING_BASE64", "DOCS_TEAM_ROSTER_TOKEN", "HOME_DIRECTORY_ORIGIN"}, |
| - "slides": {"HOME_DIRECTORY_ORIGIN", "SLIDES_HOME_CONSUMER_ID", "SLIDES_HOME_DEK_BASE64", "SLIDES_HOME_ISSUER", "SLIDES_HOME_KEYS_BASE64", "SLIDES_INSTANCE_KEY", "SLIDES_ORIGIN", "SLIDES_TEAM_DIRECTORY_ORIGIN", "SLIDES_TEAM_ID", "SLIDES_TEAM_OPERATOR_KEYS_BASE64", "SLIDES_TEAM_PROVISIONING_BASE64", "SLIDES_TEAM_ROSTER_TOKEN"}, |
| - "memoria": {"HOME_DIRECTORY_ORIGIN", "MEMORIA_DEK", "MEMORIA_HOME_CONSUMER_ID", "MEMORIA_HOME_DEK_BASE64", "MEMORIA_HOME_ISSUER", "MEMORIA_HOME_KEYS_BASE64", "MEMORIA_INSTANCE_KEY", "MEMORIA_ORIGIN", "MEMORIA_TEAM", "MEMORIA_TEAM_DIRECTORY_ORIGIN", "MEMORIA_TEAM_ID", "MEMORIA_TEAM_OPERATOR_KEYS_BASE64", "MEMORIA_TEAM_PROVISIONING_BASE64", "MEMORIA_TEAM_ROSTER_TOKEN"}, |
| - "sheets": {"HOME_DIRECTORY_ORIGIN", "SHEETS_DEK", "SHEETS_HOME_CONSUMER_ID", "SHEETS_HOME_DEK_BASE64", "SHEETS_HOME_ISSUER", "SHEETS_HOME_KEYS_BASE64", "SHEETS_INSTANCE_KEY", "SHEETS_ORIGIN", "SHEETS_TEAM_DIRECTORY_ORIGIN", "SHEETS_TEAM_ID", "SHEETS_TEAM_OPERATOR_KEYS_BASE64", "SHEETS_TEAM_PROVISIONING_BASE64", "SHEETS_TEAM_ROSTER_TOKEN"}, |
| + "docs": {"DOCS_ALLOWED_ADDRESSES", "DOCS_CONTENT_KEY", "DOCS_HOME_CONSUMER_ID", "DOCS_HOME_DEK_BASE64", "DOCS_HOME_ISSUER", "DOCS_HOME_KEYS_BASE64", "DOCS_INSTANCE_KEY", "DOCS_ORIGIN", "DOCS_TEAM_DIRECTORY_ORIGIN", "DOCS_TEAM_ID", "DOCS_TEAM_OPERATOR_KEYS_BASE64", "DOCS_TEAM_PROVISIONING_BASE64", "DOCS_TEAM_ROSTER_TOKEN", "HOME_DIRECTORY_ORIGIN"}, |
| + "slides": {"HOME_DIRECTORY_ORIGIN", "SLIDES_HOME_CONSUMER_ID", "SLIDES_HOME_DEK_BASE64", "SLIDES_HOME_ISSUER", "SLIDES_HOME_KEYS_BASE64", "SLIDES_INSTANCE_KEY", "SLIDES_ORIGIN", "SLIDES_TEAM_DIRECTORY_ORIGIN", "SLIDES_TEAM_ID", "SLIDES_TEAM_OPERATOR_KEYS_BASE64", "SLIDES_TEAM_PROVISIONING_BASE64", "SLIDES_TEAM_ROSTER_TOKEN"}, |
| + "memoria": {"HOME_DIRECTORY_ORIGIN", "MEMORIA_DEK", "MEMORIA_HOME_CONSUMER_ID", "MEMORIA_HOME_DEK_BASE64", "MEMORIA_HOME_ISSUER", "MEMORIA_HOME_KEYS_BASE64", "MEMORIA_INSTANCE_KEY", "MEMORIA_ORIGIN", "MEMORIA_TEAM", "MEMORIA_TEAM_DIRECTORY_ORIGIN", "MEMORIA_TEAM_ID", "MEMORIA_TEAM_OPERATOR_KEYS_BASE64", "MEMORIA_TEAM_PROVISIONING_BASE64", "MEMORIA_TEAM_ROSTER_TOKEN"}, |
| + "calendar": {"CALENDAR_DEK", "CALENDAR_HOME_CONSUMER_ID", "CALENDAR_HOME_DEK_BASE64", "CALENDAR_HOME_ISSUER", "CALENDAR_HOME_KEYS_BASE64", "CALENDAR_INSTANCE_KEY", "CALENDAR_ORIGIN", "CALENDAR_TEAM_DIRECTORY_ORIGIN", "CALENDAR_TEAM_ID", "CALENDAR_TEAM_OPERATOR_KEYS_BASE64", "CALENDAR_TEAM_PROVISIONING_BASE64", "CALENDAR_TEAM_ROSTER_TOKEN", "HOME_DIRECTORY_ORIGIN"}, |
| + "sheets": {"HOME_DIRECTORY_ORIGIN", "SHEETS_DEK", "SHEETS_HOME_CONSUMER_ID", "SHEETS_HOME_DEK_BASE64", "SHEETS_HOME_ISSUER", "SHEETS_HOME_KEYS_BASE64", "SHEETS_INSTANCE_KEY", "SHEETS_ORIGIN", "SHEETS_TEAM_DIRECTORY_ORIGIN", "SHEETS_TEAM_ID", "SHEETS_TEAM_OPERATOR_KEYS_BASE64", "SHEETS_TEAM_PROVISIONING_BASE64", "SHEETS_TEAM_ROSTER_TOKEN"}, |
| } |
| for slug, names := range want { |
| app, _ := AppBySlug(slug) |
| @@ -45,7 +48,7 @@ func TestRosterRecipes(t *testing.T) { |
| } |
| } |
| for _, a := range Apps { |
| - if a.Roster != (a.Slug == "docs" || a.Slug == "sheets" || a.Slug == "slides" || a.Slug == "memoria") { |
| + if a.Roster != (a.Slug != "calls") { |
| t.Fatalf("%s roster mode %v", a.Slug, a.Roster) |
| } |
| } |
diff --git a/provision/review_test.go b/provision/review_test.go| index ea32fbb..2c83335 100644 |
| --- a/provision/review_test.go |
| +++ b/provision/review_test.go |
| @@ -25,7 +25,7 @@ func TestOwnerForgottenWhileAnAppIsParked(t *testing.T) { |
| if r.State != "parked" { |
| t.Fatalf("run %s %s", r.State, r.Code) |
| } |
| - for _, app := range []string{"docs", "sheets", "slides", "memoria"} { |
| + for _, app := range []string{"docs", "sheets", "slides", "calendar", "memoria"} { |
| if st, _, _ := h.store.Step(h.ctx(), "lagged", app, StepVerify); st.Code != "no-readiness-probe" { |
| t.Fatalf("%s verify %s %s", app, st.State, st.Code) |
| } |
| @@ -44,11 +44,11 @@ func TestOwnerForgottenWhileAnAppIsParked(t *testing.T) { |
| if h.scan(ownerCanary) { |
| t.Fatal("owner address in Alta's database files") |
| } |
| - // The apps without roster mode finished: their allowlists hold the |
| - // owner. |
| - vars, _, _ := h.con.Env("calendar", "lagged") |
| - if vars["CALENDAR_ALLOWED_ADDRESSES"].Value != ownerCanary { |
| - t.Fatal("calendar allowlist not written") |
| + // Calls, the one app without roster mode, finished: its allowlist |
| + // holds the owner. |
| + vars, _, _ := h.con.Env("calls", "lagged") |
| + if vars["CALLS_ALLOWED_ADDRESSES"].Value != ownerCanary { |
| + t.Fatal("calls allowlist not written") |
| } |
| } |