-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add PR previews with Netlify (#5787)
It would be preferable to only generate these for UI PRs but Netlify appears to not have that flexibility. I tried setting up manual deployments in a Travis environment but gave up the experiment; it could probably eventually work if deployment failures become a nuisance.
- Loading branch information
Showing
2 changed files
with
21 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"siteId": "a3e19a5f-a18e-40b7-b943-bd0f96ba354f" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# Netlify is installed under the hc-nomad bot account on GitHub. | ||
|
||
[build] | ||
# The generated site needs to live at /ui/, so this moves it there after building. | ||
command = "ember build && mkdir -p ui-dist/ui && mv dist/* ui-dist/ui/" | ||
base = "ui" | ||
publish = "ui/ui-dist" | ||
|
||
# This ensures that following the link from the PR checks list redirects to the subdirectory. | ||
[[redirects]] | ||
from = "/" | ||
to = "/ui/" | ||
|
||
# This catches other unknown URLs and lets Ember handle them. | ||
[[redirects]] | ||
from = "/*" | ||
to = "/ui/index.html" | ||
status = 200 |