refs https://github.com/TryGhost/Ghost/issues/7907
- rather than forwarding the redirect URI as configured in Ghost we should use the URL that the admin client is currently loaded on when setting the Ghost OAuth `redirectUri` attribute
- fixes issue with the admin app loading inside of the OAuth popup window and not logging in when using https with a registered http redirect uri
no issue
- use the configured `blogUrl` value rather than using `window.location.href` with a poor regex that was incorrectly matching on domains containing multiple `/ghost` parts such as `http://ghost.local:2368/ghost`
refs TryGhost/Ghost#7628 (issue), refs TryGhost/Ghost#7631 (required)
- update `config` service to fetch from public configuration endpoint
- add `beforeModel` to `application` route to fetch config and pause further processing until the request is complete
- remove `<meta name="env-*">` tags from generated `default.hbs` and internal testing `index.html`
- add mirage config to simulate configuration endpoint and helper to simulate enabled oauth config
- update `ghost-oauth2` torii provider to use auth server URL from server-provided config
issue TryGhost/Ghost#7452, requires TryGhost/Ghost#7451
- use a `ghostOAuth` config flag to switch between the old-style per-install auth and centralized OAuth auth based on config provided by the server
- add OAuth flows for:
- setup
- sign-in
- sign-up
- re-authenticate
- add custom `oauth-ghost` authenticator to support our custom data structure
- add test helpers to stub successful/failed oauth authentication
- hide change password form if using OAuth (temporary - a way to change password via oauth provider will be added later)