Skip to content

Commit 44009d7

Browse files
committed
feat(cli): OS_AUTH_PHONE_NUMBER_ENABLED switch for the phoneNumber plugin
plugins.phoneNumber existed in AuthPluginConfig (#2766) but `objectstack serve` never set it - there was no way to turn phone sign-in/OTP on from the CLI. Follows the OS_{DOMAIN}_{FEATURE}_ENABLED convention; default off. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013LXUXU66dBaP3SSG4ZVtuH
1 parent 0da5470 commit 44009d7

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

packages/cli/src/commands/serve.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1259,6 +1259,12 @@ export default class Serve extends Command {
12591259
// operator override (env wins in buildPluginList()).
12601260
passwordRejectBreached:
12611261
String(process.env.OS_AUTH_PASSWORD_REJECT_BREACHED ?? 'false').toLowerCase() === 'true',
1262+
// #2766/#2780 — phone-number sign-in (phone+password always;
1263+
// OTP sign-in/reset once the sms capability has a deliverable
1264+
// provider). Opt-in: without this env the config flag had no
1265+
// `objectstack serve` switch at all.
1266+
phoneNumber:
1267+
String(process.env.OS_AUTH_PHONE_NUMBER_ENABLED ?? 'false').toLowerCase() === 'true',
12621268
},
12631269
advanced: process.env.OS_COOKIE_DOMAIN
12641270
? ({

0 commit comments

Comments
 (0)