Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
Pulsar
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue 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
NDIP
Pulsar
Commits
a56a7e08
Commit
a56a7e08
authored
11 years ago
by
John Chilton
Browse files
Options
Downloads
Patches
Plain Diff
Touch up configure_test_slurm.py for non-my-laptop setups.
parent
c9a97550
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
scripts/configure_test_slurm.py
+3
-2
3 additions, 2 deletions
scripts/configure_test_slurm.py
with
3 additions
and
2 deletions
scripts/configure_test_slurm.py
+
3
−
2
View file @
a56a7e08
from
socket
import
gethostname
from
string
import
Template
from
subprocess
import
call
from
getpass
import
getuser
SLURM_CONFIG_TEMPLATE
=
'''
# slurm.conf file generated by configurator.html.
...
...
@@ -33,7 +34,7 @@ SlurmctldPort=6817
SlurmdPidFile=/var/run/slurmd.pid
SlurmdPort=6818
SlurmdSpoolDir=/tmp/slurmd
SlurmUser=
john
SlurmUser=
$user
#SlurmdUser=root
#SrunEpilog=
#SrunProlog=
...
...
@@ -80,7 +81,7 @@ PartitionName=debug Nodes=$hostname Default=YES MaxTime=INFINITE State=UP
def
main
():
template_params
=
{
"
hostname
"
:
gethostname
()}
template_params
=
{
"
hostname
"
:
gethostname
()
,
"
user
"
:
getuser
()
}
config_contents
=
Template
(
SLURM_CONFIG_TEMPLATE
).
substitute
(
template_params
)
open
(
"
/etc/slurm-llnl/slurm.conf
"
,
"
w
"
).
write
(
config_contents
)
call
(
"
slurmctld
"
)
...
...
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