A client is configuration: from client.yaml to a served tenant

A client is configuration: from client.yaml to a served tenant A workflow diagram generated by Archify. 01 / clients/<slug>: client.yaml + assets/ · no Go 02 / apps/flagship · one image, every client 03 / kit/app App.Run · hosts.<env> Select Compose First tenant Serve client.yaml · in clients/<slug>/ · clients/<slug>: client.yaml + assets/ · no Go › Select · + assets/ · no Go client.yaml in clients/<slug>/ + assets/ · no Go LoadClient(slug) · PLATFORMKIT_CLIENTS_DIR · clients/<slug>: client.yaml + assets/ · no Go › Select · clients/ or embedded LoadClient(slug) PLATFORMKIT_CLIENTS_DIR clients/ or embedded bootstrap? · password printed once · clients/<slug>: client.yaml + assets/ · no Go › First tenant · yes: tenant + admin bootstrap? password printed once yes: tenant + admin flagship · --client <slug> --env · apps/flagship · one image, every client › Select · PLATFORMKIT_CLIENT flagship --client <slug> --env PLATFORMKIT_CLIENT compose() · registry.go: Requires/Build · apps/flagship · one image, every client › Compose · audit 2nd-last, admin last compose() registry.go: Requires/Build audit 2nd-last, admin last run --role · web | worker | all · apps/flagship · one image, every client › Serve · one flagship image run --role web | worker | all one flagship image db.Migrate · per owner, in order · kit/app App.Run · hosts.<env> › Compose · in composition order db.Migrate per owner, in order in composition order <host>/admin · storefront: / and /me · kit/app App.Run · hosts.<env> › Serve · web role serves <host>/admin storefront: / and /me web role serves slug Client App.Run up to date then run web role Legend User UI Agent logic Policy Context / trace Cloud service External system

One image, many clients

  • • One flagship image serves every client
  • • the chart's values per client live beside it

Refused by name

  • • LoadClient: unknown key or --env without a host
  • • compose(): unknown module or missing Requires

What compose() wires

  • • registry.go orders: audit next to last, admin last
  • • a private provider implements billing.PaymentProvider