使用浏览器 OIDC 或用户名/密码向代理引擎进行身份验证。
Synopsis
进行身份验证并存储本地身份验证状态。Browser OIDC 是默认设置;--username 选择用户名/密码登录,--from-refresh-token 交换 AGENTENGINE_REFRESH_TOKEN。
--password 和 --password-stdin 需要 --用户名。--from-refresh-token 不能与 --username、用户名 或 --password-stdin 结合使用。
agentengine auth login [flags]示例
agentengine auth loginsecret-manager read AGENTENGINE_PASSWORD | agentengine auth login --username user@example.com --password-stdin选项
--base-url string Agent Engine API base URL (default "https://agentengine.mongodb.com") --callback-port int Pin the local login callback port so an SSH tunnel can be reused across logins (default: random; AGENTENGINE_LOGIN_CALLBACK_PORT also sets this) --from-refresh-token Exchange AGENTENGINE_REFRESH_TOKEN for a fresh login session without browser SSO-h, --help help for login --json Output login result as JSON --no-browser Print the login URL without attempting to open a browser --password-stdin Read the password from stdin (piped or redirected); requires --username --timeout duration Maximum time to wait for browser authentication (default 2m0s) --username string Username for credential-based authentication从父命令继承的选项
--log-file string override log file path --log-level string file log verbosity (error|warn|info|debug) (default "info") --no-log disable file logging-q, --quiet silence stderr below error-v, --verbose count raise stderr verbosity (-v info, -vv debug)另请参阅
- agentengine auth - 身份验证命令。