sync: update from private repo (521808b)
Some checks failed
CI / build-and-test (push) Has been cancelled
Some checks failed
CI / build-and-test (push) Has been cancelled
This commit is contained in:
parent
8041bc62cc
commit
4601e8d5c3
@ -17,6 +17,7 @@ export function AuthForm({ config, onChange }: SectionFormProps) {
|
||||
const providers = auth.providers ?? {};
|
||||
const google = providers.google ?? {};
|
||||
const gitea = providers.gitea ?? {};
|
||||
const local = auth.local ?? {};
|
||||
|
||||
return (
|
||||
<div className="space-y-5">
|
||||
@ -33,11 +34,12 @@ export function AuthForm({ config, onChange }: SectionFormProps) {
|
||||
onChange={e => onChange('auth.primaryProvider', e.target.value)}
|
||||
className="w-full h-8 px-2 text-[13px] border border-hairline rounded-md bg-canvas focus:ring-2 focus:ring-accent-ring focus:border-accent outline-none transition-shadow"
|
||||
>
|
||||
<option value="">(指定なし・両方有効)</option>
|
||||
<option value="">(指定なし・全て有効)</option>
|
||||
<option value="google">google のみ</option>
|
||||
<option value="gitea">gitea のみ</option>
|
||||
<option value="local">local のみ</option>
|
||||
</select>
|
||||
<HelpText>単一プロバイダーに限定する場合に指定。未指定なら設定済みの全プロバイダーでログイン可</HelpText>
|
||||
<HelpText>単一プロバイダーに限定する場合に指定。未指定なら設定済みの全プロバイダー(OAuth + ローカル)でログイン可</HelpText>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
@ -73,6 +75,27 @@ export function AuthForm({ config, onChange }: SectionFormProps) {
|
||||
<HelpText>セッション署名鍵。十分長いランダム文字列を設定(保存後はマスク表示)</HelpText>
|
||||
</div>
|
||||
|
||||
<h3 className="text-sm font-medium text-slate-600 mt-4 pt-3 border-t border-slate-200">ローカルアカウント(email + password)</h3>
|
||||
<div>
|
||||
<label className="flex items-center gap-2 text-sm text-slate-700">
|
||||
<input type="checkbox" checked={local.enabled === true}
|
||||
onChange={e => onChange('auth.local.enabled', e.target.checked)} className="rounded" />
|
||||
ローカルログインを有効化
|
||||
</label>
|
||||
<HelpText>外部 IdP を立てずに email/password でログインできるようにする。OAuth と併用可(<code>primary_provider: local</code> で local のみに限定)</HelpText>
|
||||
</div>
|
||||
<div>
|
||||
<label className="flex items-center gap-2 text-sm text-slate-700">
|
||||
<input type="checkbox" checked={local.allowSignup === true}
|
||||
onChange={e => onChange('auth.local.allowSignup', e.target.checked)} className="rounded" />
|
||||
セルフ登録を許可
|
||||
</label>
|
||||
<HelpText>ログイン画面に新規登録フォームを出す。登録は <strong>承認待ち</strong>で作成され、admin がユーザー管理で承認するまでログインできない</HelpText>
|
||||
</div>
|
||||
<HelpText>
|
||||
初回 admin(<code>bootstrap_admin</code>)は、UI に入るには既に admin ログインが必要なため、<code>config.yaml</code> の <code>auth.local.bootstrap_admin</code> で設定します(<code>id='local'</code> で seed され、no-auth 時代のデータを引き継ぎます)。以降のユーザーは <em>ユーザー管理</em> 画面で作成・パスワードリセットできます。
|
||||
</HelpText>
|
||||
|
||||
<h3 className="text-sm font-medium text-slate-600 mt-4 pt-3 border-t border-slate-200">Google OAuth</h3>
|
||||
<div>
|
||||
<FieldLabel>Client ID</FieldLabel>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user