Giter VIP home page Giter VIP logo

Comments (3)

marcelgerber avatar marcelgerber commented on June 9, 2024

I tried moving it to CF Pages (which would be the easiest option given the existing _redirects file and such), but we cannot do that since there are several files that are over the 25MB limit.

Instead, I then tried uploading these files to R2 (bucket covid-19) and made that bucket publicly available at https://covid.owid.io.
In addition, I set up Bulk redirects and Response header transform rules in the Cloudflare dashboard, to match _headers and _redirects as closely as possible.
That seems to have worked pretty well.

There are a few slight differences:

  • I couldn't replicate the code-200 redirects from Netlify, so instead these are 301s now.
  • I checked, and both CF and DO return Access-Control-Allow-Origin: * headers, but only if an Origin header is present on the header.

Outstanding steps:

  • Test that explorer files load just fine from covid.owid.io
  • Copy these bulk redirects and transform rules over to apply to covid.ourworldindata.org
  • Update the existing on-deploy workflow to instead upload these files to R2.
  • Switch covid.ourworldindata.org over to point to R2.
  • Remove the _redirects and _headers files, since redirects and headers will have to be set up differently in the future.

from covid-19-data.

danyx23 avatar danyx23 commented on June 9, 2024

Sounds good to me. Without diving into it too much it could be that some scripts break if we change the status code of redirects but at this point I think this is no big deal. Sounds good to me!

from covid-19-data.

marcelgerber avatar marcelgerber commented on June 9, 2024

This is mostly done now, just keeping this issue open until #2820 is merged with some cleanup work.

from covid-19-data.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.