v4: a deployment chooses which ways federated sign-in goes — every instance took users of the others and let its own sign in to them, with no way to turn either off. GERBEUR_FEDERATION_INCOMING=0 keeps users of other instances out: the login and register pages offer no other instance, /manage no list of instances, their sign-ins are refused, and those already in are signed out until it is on again, their homes' events still applied meanwhile. GERBEUR_FEDERATION_OUTGOING=0 keeps the instance's users from signing in elsewhere: its /authorize page lets no instance sign them in, its metadata says so (gerbeur_outgoing), which other instances check before sending anyone there, the settings page lists no instances, and at startup every grant is withdrawn, which signs them out there. Both are on by default and reach the client through index.html. The dev instance gerbeur (:3000) takes no users of the others, while its own still sign in to them.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -34,17 +34,25 @@ export interface DevInstance {
|
||||
webPort: number;
|
||||
/**
|
||||
* `GERBEUR_*` settings of its own, over the base `.env`: a site name, an
|
||||
* emoji or a style, to tell the instances apart.
|
||||
* emoji or a style, to tell the instances apart, or which ways federated
|
||||
* sign-in goes.
|
||||
*/
|
||||
env?: Record<string, string>;
|
||||
}
|
||||
|
||||
/**
|
||||
* The instances `deno task dev` starts, in this order. The first keeps the
|
||||
* ports the single dev server always had.
|
||||
* ports the single dev server always had, and takes no users of the others,
|
||||
* while its own sign in to them, so that both switches of federated sign-in
|
||||
* can be tried.
|
||||
*/
|
||||
export const INSTANCES: readonly DevInstance[] = [
|
||||
{ name: "gerbeur", apiPort: 8000, webPort: 3000 },
|
||||
{
|
||||
name: "gerbeur",
|
||||
apiPort: 8000,
|
||||
webPort: 3000,
|
||||
env: { GERBEUR_FEDERATION_INCOMING: "0" },
|
||||
},
|
||||
{
|
||||
name: "musique",
|
||||
apiPort: 8001,
|
||||
|
||||
Reference in New Issue
Block a user