Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multi-stage docker build #122

Merged
merged 16 commits into from
Jan 9, 2024
Merged

Multi-stage docker build #122

merged 16 commits into from
Jan 9, 2024

Conversation

iamtroy412
Copy link
Member

This PR is for a multi-stage docker build of the slurm test environment. This will allow us to remove the static RPMs from git and build them as new slurm versions are added to the test list. The first stage installs the required devel packages for all possible plugins then builds the slurm RPMs. The second stage copies in the slurm RPMs from the first stage and installs them.

  • Removes version 20.02.5. As slurm versions are removed from the download archive, they should be dropped from testing
  • Add version 22.05.11, the version currently running on the cluster
  • Removed rpms from git
  • Build and install the slurmrestd package by default

Tested locally using;
podman build -t slurm-test-env:22.05.11 -f Dockerfile --build-arg SLURM_VERSION=22.05.11
podman run -it --rm -v ./tests/:/tests localhost/slurm-test-env:22.05.11 bats /tests

@iamtroy412
Copy link
Member Author

github actions files need to be updated, but wanted to get any feedback from testing locally first.

Copy link
Member

@djperrefort djperrefort left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes to the docker file look good. Doesn't the entrypoint script need updating to launch the rest API daemon? I tried running the slurmrestd command from within the container but I get the following error:

slurmrestd: fatal: Unable to unshare System V namespace: Operation not permitted

@iamtroy412
Copy link
Member Author

iamtroy412 commented Jan 8, 2024

Yeah, the entrypoint script needs to be updated, as well as the slurm.conf files to enable the JWT auth to the slurmctld daemon. I'd like to address that in a different PR though, and keep this one just to the multi-stage build and building/installing the slurmrestd package. I'll reference #116 in a new PR that sets up and configures the rest daemon.

@djperrefort
Copy link
Member

SGTM. Merge at will.

@iamtroy412 iamtroy412 merged commit 3d4092a into latest Jan 9, 2024
6 checks passed
@iamtroy412 iamtroy412 deleted the multi-stage branch January 9, 2024 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants