PhoenixKit 1.4.1: Connected accounts, OAuth behind proxies, maintenance mode
PhoenixKit 1.4.1 lets users manage their OAuth sign-ins themselves and adds a maintenance mode for the whole site.
The account settings page has a Connected Accounts section: users see which providers are linked and can connect Google, Apple, GitHub or Facebook, or disconnect one. The provider account must use the same email as the PhoenixKit account, and a user always keeps at least one way to sign in, a password or a provider. In the admin settings, Google OAuth gets step-by-step setup instructions with the callback address to copy.
OAuth callbacks now work behind a reverse proxy: PhoenixKit reads the X-Forwarded-Proto header to build https addresses, and config :phoenix_kit, oauth_base_url: "https://example.com" covers the remaining cases.
The new Maintenance Mode module shows a maintenance page to everyone except admins and owners, with your own Header Text and Message Text.
Upgrading
New installs add plug PhoenixKitWeb.Plugs.Integration to the :browser pipeline. In an existing app, add that line yourself so maintenance mode also covers your app’s own pages.
PhoenixKit 1.4.1. Install or update: {:phoenix_kit, "~> 1.4"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.