Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't rely on GitHub directly for updates #189

Closed
MartinKolarik opened this issue Oct 20, 2023 · 14 comments · Fixed by #217
Closed

Don't rely on GitHub directly for updates #189

MartinKolarik opened this issue Oct 20, 2023 · 14 comments · Fixed by #217

Comments

@MartinKolarik
Copy link
Member

GitHub doesn't support IPv6 so probes in IPv6-only networks won't be able to reach it.

@MartinKolarik
Copy link
Member Author

Here's a question of how we do this as well. We could use https://data.jsdelivr.com/v1/packages/gh/jsdelivr/globalping-probe if we add AAAA for the data domain (www already has it), and Bunny supports it, so it should be fine.

However, render.com doesn't support IPv6 yet, so if we ever need to remove the CDN, it suddenly creates a problem. Custom endpoint on our CDN is also an option if we can guarantee all providers support IPv6 (which we should), or there's an option of something entirely custom outside jsDelivr.

@jimaek
Copy link
Member

jimaek commented Mar 17, 2024

I think using an ipv6 CDN on top of data.jsd is fine, using it without it is a no go either way since their bandwidth is super expensive

@jimaek
Copy link
Member

jimaek commented Mar 17, 2024

btw we dont need to add anything, data.jsd is already ipv6 enabled

@MartinKolarik
Copy link
Member Author

using it without it is a no go either way since their bandwidth is super expensive

It is no go long-term but short-term if Bunny has issues, our first resort might be removing it for a day. We have done it a couple of times already. We can go this way, just need to be more careful when making changes to consider this aspect.

btw we dont need to add anything, data.jsd is already ipv6 enabled

Indeed.

@MartinKolarik
Copy link
Member Author

Adding "on hold" until we resolve the IPv6 DNS issue in the US.

@MartinKolarik
Copy link
Member Author

Just a note here that if we only need the latest version, https://data.jsdelivr.com/v1/packages/gh/jsdelivr/globalping-probe/resolved is an easier way to get it.

@MartinKolarik
Copy link
Member Author

This is trickier than I realized at first because after we get the version (from data.jsd) we need to get the URL of the actual release and then download it, and that's another GH API call - but one that can't be replaced by our own API. Custom CDN option seems like the best way to handle this?

@jimaek
Copy link
Member

jimaek commented Apr 16, 2024

But what do we proxy with the CDN? The GitHub API directly?

@MartinKolarik
Copy link
Member Author

We need two things:

  1. https://api.github.com/repos/jsdelivr/globalping-probe/releases/latest - gives us version / link to the release
  2. https://github.com/jsdelivr/globalping-probe/releases/download/v0.29.0/globalping-probe.bundle.tar.gz - this is the asset URL

They are at different domains, so I'd do this:

  1. Use data API to get the version.
  2. Construct the link manually and get cdn.jsdelivr.net/globalping-probe/{{version}}/globalping-probe.bundle.tar.gz (we have a setup like this for musescore/atlas already)

MartinKolarik added a commit to MartinKolarik/globalping-probe that referenced this issue Apr 17, 2024
# Conflicts:
#	bin/entrypoint.sh
#	src/index.ts
MartinKolarik added a commit to MartinKolarik/globalping-probe that referenced this issue Apr 17, 2024
MartinKolarik added a commit to MartinKolarik/globalping-probe that referenced this issue Apr 17, 2024
@jimaek
Copy link
Member

jimaek commented Apr 17, 2024

How about adding a failover to those domains? e.g. if cdn.jsdelivr.net is not available, try fastly.jsdelivr.net

@MartinKolarik
Copy link
Member Author

I could do it for .net, but we don't have another domain for data (and that's also queried in multiple places, so could become messy). Also, if either of the services is down, it doesn't matter to the probe, it'll update later. Only possible issue is if the domain got blocked in some country I guess.

@jimaek
Copy link
Member

jimaek commented Apr 17, 2024

Lets do it for .net just in case

@MartinKolarik
Copy link
Member Author

Ok, updated.

Copy link

🎉 This issue has been resolved in version 0.30.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants