feat: Add slurm prometheus exporter to snapcraft.yaml recipe #9
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request adds the Slurm prometheus exporter into the snap image for Slurm. The part clones the exporter from GitHub and builds using
swig
to bind to slurm/slurm.h. I also added a simple daemon for the exporter that can be started once all the other Slurm services have been started on the cluster.What still needs to be done
I need to add integration tests for the snap package in general. Testing can be done manually using a local LXD installation, but it would be great to have something that just sets up a minicluster and ensures that all the snap services + prometheus exporter are working. I will add this in a subsequent pull request; I've done something similar before here: https://nuccitheboss.github.io/cleantest/tutorials/using-a-mini-hpc-cluster/
Misc
SLURM_CONF
as global environment variable rather than having it scoped individually to each command. Functionally it's similar to how it was defined before, but now if we need to update the location of the slurm.conf configuration file, we only have to change on value rather than dozens!