HomePhabricator

Fix excessively severe CSP URI error during first-time setup

Description

Fix excessively severe CSP URI error during first-time setup

Summary:
See D19394. Currently, during first-time setup before you configure "phabricator.base-uri", we may attempt to generate a setup page, try to generate a CSP header for it, and fail to access the environmental config. This causes a too-severe error page ("configure phabricator.base-uri") instead of preflight guidance (like "can't connect to MySQL").

Instead, treat this more like "security.alternate-file-domain" and just bail on CSP if we can't fetch it.

Test Plan: On a fresh (non-explodey laptop) install with critical setup errors (no MySQL installed yet), loaded Phabricator. Before: error about phabricator.base-uri. After: more helpful guidance about installing/configuring MySQL.

Reviewers: amckinley, avivey

Reviewed By: amckinley

Differential Revision: https://secure.phabricator.com/D19396

Details

Provenance
epriestleyAuthored on Apr 21 2018, 4:08 PM
epriestleyPushed on Apr 21 2018, 4:43 PM
Reviewer
amckinley
Differential Revision
D19396: Fix excessively severe CSP URI error during first-time setup
Parents
rP33da9f833fdd: Fix odd line number line wrapping on embedded pastes (`{Pxxx}`)
Branches
Unknown
Tags
Unknown
Build Status
Buildable 20210
Build 27425: Run Core Tests