tristanpemble / nix-nomad

HashiCorp Nomad job definitions in Nix
https://tristanpemble.github.io/nix-nomad/
MIT License
66 stars 6 forks source link

chore: Update definitions to Nomad 1.5.17 #8

Closed Lixivial closed 5 months ago

Lixivial commented 5 months ago

Nomad-specific updates:

Various updates:

tristanpemble commented 5 months ago

hey there 👋

before I merge; were you able to run the changes on your stack successfully? I don't have a great way to test this out at the moment

Lixivial commented 5 months ago

hey there 👋

before I merge; were you able to run the changes on your stack successfully? I don't have a great way to test this out at the moment

Yep, though we're in the process of actively upgrading our cluster to 1.5 (eventually trying to get to 1.7 sometime after NixOS 24.05 lands).

Anyway, we've produced jobspecs from this and had those accepted and successfully allocated by both our current Nomad 1.3 & test Nomad 1.5 clusters. I haven't exercised the handful of new additions in 1.5, however. I can hold and resubmit the PR until we've fully vetted each of our jobspecs, if you'd prefer. I can also whip up some test cases for some of the new properties in 1.5, as well.

As an aside, I had started putting together some generator tests, but wasn't super sure what would be the best areas to test. It felt like I was mostly testing library code (like the strcase lib) more than the actual bridge code from Go to Nix, but if there are ideas of where to add some beneficial test coverage, I can certainly take a look at that.

tristanpemble commented 5 months ago

heh, as you can probably tell now, that code was written to get the job done without regard to much else.. that's to say I don't think this is very unit testable in its current form. I'd guess that you all are the biggest user of this, so if that whole system we built there ran clean, I'm happy to merge this

integration tests could go a long way, though. I think I was using the examples folder as crude hand-run integration tests.

unfortunately we're not using Nomad, so I don't have a lot of time to give this, but if you find it valuable I'm happy to accept PRs or answer any questions I can still answer

tristanpemble commented 5 months ago

@Lixivial I remembered I had set up a Flake check as a crude check