Introducing FlakeHub

Graham has mentioned the planned future support for other forges. That aside, it is possible, as a workaround, to create a GitHub repository which takes care of this. Any repository owned by you on GitHub can publish flakes under any name on the fgaz namespace on FlakeHub, so you could have a single repository that fetches your projects from other forges and publishes them to FlakeHub from there.

1 Like

Totally understood, no worries. I’d like to see the primitives built in to Nix, too.

2 Likes

Unfortunately that’s forbidden by the GitHub terms of service:

Actions should not be used for:
[…]

  • if using GitHub-hosted runners, any other activity unrelated to the production, testing, deployment, or publication of the software project associated with the repository where GitHub Actions are used.

edit: and it requires a GitHub account. I still have one so I can contribute to other people’s projects, but many people don’t

3 Likes

Dang, good to know – thank you. Well. Maybe don’t do that then :). We’ll be getting a good solution into folks hands in the coming weeks.

I’m sorry some folks aren’t excited about FlakeHub, but that is okay. We’ve made it because it solves real problems we’ve experienced, and I think it is going to make a big difference in the community. We’re all contributing to the project in the ways we want to, and this is an example of that.

We see flakes as the future of Nix, and we’re unabashedly working to make that true. One way we’re doing that is using flakes extensively every day and exposing ourselves to the bugs, papercuts, and pain points. We often deeply research and resolve these problems upstream, without fanfare or posting on Discourse.

I think we have the common goal of growing and improving Nix, and we’re glad to be doing it together. We would love to see a continuation of RFC-144 accepted into Nix upstream. The version resolving feature of FlakeHub is a bandaid that works until the upstream project has a comparable feature. In my opinion, it is a good thing to do experiments like this without committing the entire project to it.

26 Likes

If you have been working to resolve things upstream, then now’s a good time to mention it. Because as far as I know, all of the major problem with Flakes are still as unaddressed as they were years ago and I have not seen any contributions by DetSys in that direction, but maybe I just missed it?

Yet the RFC was closed due to lack of interest. If you knew about it, why not help out with such efforts? Similarly, I also don’t recall anybody from DetSys participating in RFC 136 (not that it’s a big milestone, but it’s going in the right direction).

34 Likes

Ok so here’s another question, couldn’t this be added to nixos-search, as it’s already an official and very popular tool? If DetSys truly feels FlakeHub is solving a real problemsthe Nix ecosystem suffers from, why not add it to Nix itself, even if for now it just means adding it tom the official search.nixos.org website?

It feels like it’s a common occurrence for DetSys to make an announcement on Discourse about a project they’ve been working on in private rather than helping with already existing community or official efforts, just like what happened with zero-to-nix.com and its feedback from the community. The lack of transparency isn’t a good look.

If you feel like the already existing efforts/projects aren’t being done right or are going in the wrong direction, can’t you communicate that publicly instead of starting (in private) a brand new third-party project? (Especially when it comes to something you claim it “solves real problems” and that it will make “a big difference in the community”)

We often deeply research and resolve these problems upstream,

What went wrong in FlakeHub’s case? Why was this not resolved in upstream? (maybe search.nixos.org?) It seems search.nixos.org already supports some sort of Flake-related functionality.

28 Likes

Maybe it’s so they can charge money for premium features like “private caches”.

I would be very happy if Flakes just became a Determinate Systems project that was not part of the Nix repo. I don’t like maintaining Flakes, and if they were taken over like that then they would not longer be partially my problem (as a Nix Team member). Determinate Systems can them evolve them as they see fit. Win—Win!

32 Likes

Maybe like that we can finally get people paid for working strictly on flakes full-time :grin:

2 Likes

I think that the way in which this was developed and in which it is being presented makes it very clear that you are not doing this for the good of the community, since in that case you could have involved the community, developed this in the open as part of the nix FOSS project, and offered to host it on community infrastructure.

But you didn’t do any of that, and I don’t think we need a proprietary walled garden as part of the nix ecosystem.

16 Likes

Not really a fan, as it adds an huge attack surface since flakes are still not signed in any way. Would be fine as an index but not as an proxy.

9 Likes

IMO, it would be really great to have Determinate Systems publicly back https://github.com/NixOS/rfcs/blob/c8569f6719356009204133cd00d92010889ed56d/rfcs/0136-stabilize-incrementally.md

3 Likes

I’m a relative newcomer to the Nix world, but this whole flakes situation is a complete mess. Just for the record, I have no affiliation with DetSys.

From a documentation perspective, from a usability perspective, from an optics perspective. This thread takes what is ostensibly an effort to move things forward and devolves into a slinging match about everyones personal opinions on the merits of flakes rather than FlakeHub itself. Can you see how this is a bad look for the projects approachability?

I’m too new to have a strong opinion either way on flakes or FlakeHub specifically but surely if there were no problems with flakes then FH wouldn’t have been created!

As a n00b being able to track my dependencies without having to keep track of upstream releases seems like a hugely beneficial thing. And DetSys has done nothing to earn the skepticism being slung around in this thread have they (please enlighten me!)?

I guess this post is a polite way of saying you’re your own worst enemies at this point! You’re riding the crest of a hype wave as a project atm and seeing real adoption, real investment and real new users (hello, I am one). That will all evaporate if the pervading attitudes on display here don’t change imho.

25 Likes

On one hand, there is a community who loves Nix, want to make it great and open source, slowly but surely. On the other hand, you have companies willing to make profit (that’s what they exist for obviously) with Nix by making MVPs (minimum viable product) based on Nix as much/fast as possible.

At some point, it’s hard to stand in both camps IMO.

15 Likes

I just love binary evil/good oversimplifications:

  • Clearly DetSys folks aren’t a part of the community who loves Nix, and edolstra/grahamc haven’t been pillars of said community for years.
  • Clearly the community is unanimous on wanting flakes to stay experimental, and there isn’t a sizeable chunk of the community that has been relying on said experimental feature for years. Everyone just wants things to continue going slowly but surely, because it’s clearly working!
  • Clearly profit and a company’s success can’t be aligned with making Nix great and open source.

I could keep going… Of course it’s going to be “hard to stand in both camps” when those camps are made up strawmen.

39 Likes

Is there a resource that can explain to a non-programmer new user what the hell a flake even is/does? I’ve attempted to read multiple explanations making what are probably correct statements, that in practice leave me coming away with no clear understanding other than they go further as an abstraction, supposedly fixing some important problems while also adding important problems and being the future.

Things like Flakes - NixOS Wiki are impenetrable for gaining a grasp on them, if you don’t already know why they are needed.

I’m pretty sure I’m ultimately going to need pictures or flowcharts of how all these pieces relates to things, or something that walks through the syntax of a comprehensive real example.

5 Likes

Sure, there is some useful info here: Flakes — nix.dev documentation

4 Likes

I need to put some work into this page but this may help unlock things a bit: Nix flakes.

5 Likes

That’s definitely one of the best I’ve seen so far, thanks.

I’m reading it as “it’s a folder that contains a project that generates some (hopefully) reliable output of nix expressions, used for any and all possible system operations”

Which now makes sense why github is seemingly involved/mandatory

2 Likes