-
Notifications
You must be signed in to change notification settings - Fork 198
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
Slurm tests #3606
Merged
Merged
Slurm tests #3606
Changes from 10 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
8257f48
First pass at slurm tests
tylern4 c34bae4
First pass at slurm tests
tylern4 f9c7175
Get mpi4py working
tylern4 a695521
trying slurm tests
tylern4 5d84dfa
Use entrypoint to run
tylern4 56e017f
Wihtout entrypoint
tylern4 c8d43a7
Add different entrypoint
tylern4 6b20cfc
Add different entrypoint
tylern4 2c1561f
Only run on pull requests
tylern4 fa9a3ea
Merge branch 'Parsl:master' into slurm-tests
tylern4 e552010
remove config line
tylern4 3cd110c
Fix flake8 for config file
tylern4 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: Test Slurm Scheduler | ||
on: | ||
pull_request: | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-22.04 | ||
permissions: | ||
packages: read | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
container: ["ghcr.io/tylern4/slurm-standalone:slurm-24-05-0-1"] | ||
timeout-minutes: 30 | ||
|
||
container: | ||
image: ${{ matrix.container }} | ||
options: "--platform=linux/amd64 --rm -h node01" | ||
|
||
name: ${{ matrix.container }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install Dependencies and Parsl | ||
run: | | ||
CC=/usr/lib64/openmpi/bin/mpicc pip3 install . -r test-requirements.txt | ||
- name: Verify Parsl Installation | ||
run: | | ||
pytest parsl/tests/ -k "not cleannet and not unix_filesystem_permissions_required" --config parsl/tests/configs/local_threads.py --random-order --durations 10 | ||
- name: Test Parsl with Slurm Config | ||
run: | | ||
./parsl/tests/slurm-entrypoint.sh pytest parsl/tests/ -k "not cleannet and not unix_filesystem_permissions_required" --config parsl/tests/configs/slurm_local.py --random-order --durations 10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
from parsl.channels import LocalChannel | ||
from parsl.config import Config | ||
from parsl.executors import HighThroughputExecutor | ||
from parsl.launchers import SrunLauncher | ||
from parsl.providers import SlurmProvider | ||
|
||
|
||
def fresh_config(): | ||
return Config( | ||
executors=[ | ||
HighThroughputExecutor( | ||
label="docker_slurm", | ||
encrypted=True, | ||
provider=SlurmProvider( | ||
cmd_timeout=60, # Add extra time for slow scheduler responses | ||
channel=LocalChannel(), | ||
nodes_per_block=1, | ||
init_blocks=1, | ||
min_blocks=1, | ||
max_blocks=1, | ||
walltime='00:10:00', | ||
launcher=SrunLauncher(), | ||
), | ||
) | ||
], | ||
) | ||
|
||
|
||
config = fresh_config() | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/bin/bash | ||
set -e | ||
|
||
echo "---> Starting the MUNGE Authentication service (munged) ..." | ||
gosu munge /usr/sbin/munged | ||
|
||
echo "---> Starting the slurmctld ..." | ||
exec gosu slurm /usr/sbin/slurmctld -i -Dvvv & | ||
|
||
echo "---> Waiting for slurmctld to become active before starting slurmd..." | ||
|
||
echo "---> Starting the Slurm Node Daemon (slurmd) ..." | ||
exec /usr/sbin/slurmd -Dvvv & | ||
|
||
echo "---> Running user command '${@}'" | ||
exec "$@" |
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this line isn't needed and you got it by cut and pasting it from somewhere else that also doesn't need it... it also causes trouble in some situations by making configs be initialized at import (so every single test config gets initialised on every test run), rather than when the config is actually wanted.