Margo is a minimal alternate Cargo registry comprised of static files. This allows the user to have full control over how the registry is hosted. You can place the registry behind a well-known web server such as nginx or host it on something easy to set up like GitHub Pages. We provide a GitHub action to add a crate to the registry as part of your CI/CD process.
Hosting your own registry is an ideal alternative to using Git dependencies as Cargo is able to unify semver-compatible versions. This is especially useful in corporate settings where you may have a large number of internal dependencies across a large number of consumers.
Hosting your own registry can also be useful if you are unsatisfied with how crates.io operates:
-
Is the crate name you really wanted taken? Host your own registry and pick any name you want — the registry is your namespace!
-
Want to store gigabytes of asset files inside your crate? Host your own registry and use as much disk space as you want!
-
Want to have a crate with a million features? Host your own registry and revel in the combinatorial explosion of choices!