NixOS / ofborg

@ofborg tooling automation https://monitoring.ofborg.org/dashboard/db/ofborg

Home Page:https://ofborg.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Investigate integration of nixpkgs-hammering

cole-h opened this issue · comments

It would be nice to integrate nixpkgs-hammering, because the suggestions it provides are helpful. Especially if we can make it a honest-to-goodness GitHub check that supports annotating the line(s) that suggestions are referring to.

It may be better to integrate nixpkgs-hammering using a self-hosted GHA runner on Nixpkgs, rather than moving it directly into ofborg, but I'll leave this open until we decide for certain.

cc'ing @jtojnar

I'm not quite clear on what the logical relationship between Github Checks and self-hosted Github Actions Runners are, with respect to nixpkgs-hammering integration into nixpkgs.

If I understand correctly though, it seems like

  1. Github Actions and the Checks API are not really alternatives to one another. The only way to get nixpkgs-hammering producing green check marks and line-by-line annotations is to use the Checks API, which can only be run a "Github App" with the appropriate permissions on the repo.
  2. The App that's using the Checks API could be running anywhere that can receive webhooks.
  3. The App running nixpkgs-hammering could be ofborg, it could be GHA running on github's servers, or it could be GHA running in self-hosted mode.
  4. Github Actions is a "Github App", and there's a plugin for github actions that connects it to the Checks API here: https://github.com/LouisBrunner/checks-action
  5. Since nixpkgs-hammering normally has low resource requirements, I wonder if running on GHA hosted on github's servers is the easiest option?

I can look into the process of building a Github Action based on LouisBrunner/checks-action that runs nixpkgs-hammering.

I think I got this working.

See:

I wish it looked like a Review -- I don't think the way the data is presented looks that great personally. But it's better than a comment, I suppose?