Conversation
This comment was marked as outdated.
This comment was marked as outdated.
f75c6ed to
db45fce
Compare
This comment was marked as outdated.
This comment was marked as outdated.
|
Preview deployed: https://preview-1311.staging.documentcloud.org |
|
The frontend staging URL: https://staging.documentcloud.org/home/ The deploy preview appears correctly routed and is working for me. It appears sometimes the redirect back to the deploy preview times out, but refreshing the page gets me logged in anyways. |
|
Pinning & unpinning an Add-On seems to have broken |
|
When I click to dispatch an Add-On it seems to freeze the top navigation bar, the notification doesn't appear (until a refresh) and I'm unable to use any of the other dropdowns. If I have the "Explore Add-Ons" menu open and click to open an Add-On, the URL changes, but the Add-On doesn't open until a refresh |
|
The Scraper & Klaxon Add-Ons, I presume because they don't have any documents needed in their context, open in full page view instead of with the current search. We should probably default to side panel view always to make it a consistent user experience and not have to have two possible paths. For the Scraper Add-On it asks us to put in a project ID too, so we would likely grab that from the search context |
|
The staging url https://staging.documentcloud.org/home/ is an old build. It'll update when we merge this into This is the url to test: https://preview-1311.staging.documentcloud.org/ |
Yea, all the further testing was on the deploy preview |
|
Add-On issues should be fixed now. There was an infinite loop happening in the |
mitchelljkotler
left a comment
There was a problem hiding this comment.
Just want to confirm that the redirects from _redirects were implemented outside of code in Cloudflare config?
Yes. I'll add that to the deployment plan. There's no equivalent of that file in Cloudflare, so we either need to implement them in the control panel or as SvelteKit routes. Probably better to consolidate approaches anyway. |
|
I would I'd prefer to have redirects saved into the codebase. Better accountability, easier to reference, and coupled to code changes that require them. |
| @@ -0,0 +1,55 @@ | |||
| # Cloudflare Workers Deployment | |||
Still noticing this, but all other Add-Ons issues are fixed |
That's how they look in production: https://www.documentcloud.org/add-ons/MuckRock/documentcloud-scraper-addon/. We don't show the document search for Add-Ons that don't run on Documents. It's not related to this PR. |
|
Aside from the |
allanlasser
left a comment
There was a problem hiding this comment.
Everything looks good to me!
This moves us off Netlify and sets up deployments using Cloudflare Workers. It creates three distinct and separated environments:
Each one gets its own Wrangler file. Staging and production are static configs, previews are generated for each PR.
wrangler.production.jsoncdocumentcloud-frontendwww.documentcloud.orgmain)wrangler.staging.jsoncdocumentcloud-frontend-stagingstaging.documentcloud.orgmain)wrangler.preview.jsoncdc-preview-<PR#>preview-<PR#>.staging.documentcloud.orgThis gives us a staging staging server for other services to use (#1286) and gives us previews like we have on Netlify.
One thing to note here: We're creating a new worker for each PR, and deleting it when we close/merge the PR. If we need to look at an old branch, we can reopen the PR.
Deployment
When we deploy this, we should:
documentcloud-frontendworker forwww.documentcloud.orgAt that point, we'll be live on Cloudflare.
Closes #1286
Closes #1235
Closes #1257
Separately, we need to make sure these redirects are covered, either as SvelteKit routes or through the CF control panel: