Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
HPCasCode
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
hpc-team
HPCasCode
Commits
f09904c4
Commit
f09904c4
authored
5 years ago
by
Andreas Hamacher
Browse files
Options
Downloads
Patches
Plain Diff
adding an srun test
Former-commit-id:
4e35e421
parent
472d46ae
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitlab-ci.yml
+1
-0
1 addition, 0 deletions
.gitlab-ci.yml
CICD/tests/run_tests.sh
+1
-19
1 addition, 19 deletions
CICD/tests/run_tests.sh
CICD/tests/slurm/srunHostname.yml
+45
-0
45 additions, 0 deletions
CICD/tests/slurm/srunHostname.yml
with
47 additions
and
19 deletions
.gitlab-ci.yml
+
1
−
0
View file @
f09904c4
...
...
@@ -147,6 +147,7 @@ tests:
-
bash -e ./tests/run_tests.sh ManagementNodes "files/inventory.$STACKNAME" "../gc_key.pem"
-
bash -e ./tests/run_tests.sh NFSNodes "files/inventory.$STACKNAME" "../gc_key.pem"
-
bash -e ./tests/run_tests.sh SQLNodes "files/inventory.$STACKNAME" "../gc_key.pem"
-
bash -e ./tests/run_tests.sh slurm "files/inventory.$STACKNAME" "../gc_key.pem"
extended
:
stage
:
extended
...
...
This diff is collapsed.
Click to expand it.
CICD/tests/run_tests.sh
+
1
−
19
View file @
f09904c4
#!/bin/bash
function
usage
{
echo
$"Usage:
$0
{all, ComputeNodes, LoginNodes, ManagementNodes, NFSNodes, sql}"
INVENTORY_FILE KEY
echo
$"Usage:
$0
{all, ComputeNodes, LoginNodes, ManagementNodes, NFSNodes, sql
, slurm
}"
INVENTORY_FILE KEY
exit
1
}
...
...
@@ -23,22 +23,4 @@ function run_them ()
done
}
# I think I am just checking the if $1 is one of the listes strings (see usage) not proud of this at all but works
case
"
$1
"
in
all
)
;;
ComputeNodes
)
;;
ManagementNodes
)
;;
NFSNodes
)
;;
SQLNodes
)
;;
LoginNodes
)
;;
*
)
usage
esac
run_them
$1
$2
$3
\ No newline at end of file
This diff is collapsed.
Click to expand it.
CICD/tests/slurm/srunHostname.yml
0 → 100644
+
45
−
0
View file @
f09904c4
---
-
hosts
:
ManagementNodes,LoginNodes,ComputeNodes
gather_facts
:
false
tasks
:
-
name
:
add user hpctest
user
:
name
:
hpctest
shell
:
/bin/bash
become
:
true
-
hosts
:
ManagementNodes
gather_facts
:
false
tasks
:
-
name
:
Create a parent account
command
:
./sacctmgr -i add account parentAccount cluster=m3 Description="Test parent account" Organization="Monash"
args
:
chdir
:
'
/opt/slurm-19.05.4/bin'
become
:
true
register
:
result
failed_when
:
result.rc != 0 and result.stdout != " Nothing new added."
-
name
:
Create a project associated with a given parent
command
:
/opt/slurm-19.05.4/bin/sacctmgr -i add account testProject parent=parentAccount cluster=m3 Organization="Monash"
args
:
chdir
:
'
/opt/slurm-19.05.4/bin'
become
:
true
register
:
result
failed_when
:
result.rc != 0 and result.stdout != " Nothing new added."
-
name
:
Create a user and associate them with a project
command
:
/opt/slurm-19.05.4/bin/sacctmgr -i create user hpctest cluster=m3 account=testProject
args
:
chdir
:
'
/opt/slurm-19.05.4/bin'
become
:
true
register
:
result
failed_when
:
result.rc != 0 and result.stdout != " Nothing new added."
-
hosts
:
ComputeNodes
gather_facts
:
false
tasks
:
-
name
:
command
:
./srun --ntasks=1 --partition=batch hostname
args
:
chdir
:
'
/opt/slurm-19.05.4/bin/'
become
:
true
become_user
:
hpctest
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment