NebulousLabs / Sia

Blockchain-based marketplace for file storage. Project has moved to GitLab: https://gitlab.com/NebulousLabs/Sia
https://sia.tech
MIT License
2.71k stars 440 forks source link

Use vanity URL + canonical import paths #3086

Open lukechampine opened 6 years ago

lukechampine commented 6 years ago

Given the recent GitHub acquisition news, we have been considering migrating to a different repository hosting service. One consequence of this would be that all of our import paths we need to be rewritten. While this isn't difficult for us to do (a simple find-and-replace), it would break existing code that uses our github import path.

At this point, if we migrate from GitHub, this breakage is going to occur no matter what. But we can act now to prevent it from happening again. We need to do two things:

  1. Serve HTML with a <meta name="go-import"> tag on a suitable domain (e.g. sia.tech) that points to our current repository hosting service
  2. Add canonical import path comments to each of our packages (e.g. import crypto // sia.tech/Sia/crypto)

This means that if we migrate to a different hosting service, we only need to update the meta tag; the import paths themselves are unchanged. And we get a nice vanity URL. :)

tbenz9 commented 6 years ago

I believe a migration away from GitHub because of an acquisition is a brash, knee-jerk reaction. I would encourage you to let the situation play out before making such a dramatic change. Most things I've read point to GitHub not changing much. Is there something in particular that you believe will happen?

We are buying GitHub because we like GitHub; our plan is to continue to invest in the GitHub roadmap, and make GitHub better at being GitHub.

Source: Future GitHub CEO AMA -> https://www.reddit.com/r/AMA/comments/8pc8mf/im_nat_friedman_future_ceo_of_github_ama/

ChrisSchinnerl commented 6 years ago

@tbenz9 the acquisition was merely the trigger for us to take a look at Gitlab. After playing around with it, it seems to have a vastly superior set of features. Especially the CI/CD pipelines are pretty tempting. e.g. build artifacts let you download the logs of a failed test and would also allow us to simply build a signed release binaries every time new code is merged into master. Tests could also be split into jobs which can be restarted individually and run in parallel by multiple runners.

lukechampine commented 6 years ago

I think this is something we ought to do even if we don't end up migrating from GitHub. Personally, I don't expect much will change as a result of the acquisition. But Sia should own its import paths -- simple as that. Our code shouldn't become inaccessible if GitHub goes down.