Skip to content

Commit

Permalink
New role slurm-client to install a SLURM "submit-only" node.
Browse files Browse the repository at this point in the history
This is actually a dependency of the `slurm-master` and `slurm-worker`
roles, which I forgot to commit.
  • Loading branch information
riccardomurri committed May 17, 2016
1 parent 9aafea6 commit ddf28c1
Show file tree
Hide file tree
Showing 2 changed files with 71 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# slurm-client/meta/main.yml
---

dependencies:
- { role: slurm-common }
66 changes: 66 additions & 0 deletions elasticluster/share/playbooks/roles/slurm-client/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# slurm-client/tasks/main.yml
---

- name: Install required SLURM packages (Debian/Ubuntu)
package:
pkg={{item}}
state=latest
with_items:
- libpmi0-dev
- libslurm-dev
- libslurm-perl
- libslurmdb-perl
- slurm-client
- slurm-drmaa-dev
- slurm-wlm-torque
- sview
when: 'is_debian_8_or_later|bool or is_ubuntu_15_10_or_later|bool'


- block:
# since all the SLURM binaries are bundled in a single package
# `slurm-llnl`, we have to install it and *then* stop all the services
- name: Install required SLURM packages (older Debian/Ubuntu)
package:
pkg={{item}}
state=latest
with_items:
- libpmi0-dev
- libslurm-dev
- libslurm-perl
- libslurmdb-perl
- slurm-llnl
- slurm-llnl-sview
- slurm-llnl-torque
- service:
name={{item}}
enabled=no
state=stopped
with_items:
- slurm-llnl
when:
'is_debian_or_ubuntu|bool and not (is_debian_8_or_later|bool or is_ubuntu_15_10_or_later|bool)'


- block:
# since all the SLURM binaries are bundled in a single package
# `slurm`, we have to install it and *then* stop all the services
- name: Install SLURM packages (RHEL-compatible)
package:
name={{item}}
state=present
with_items:
- slurm
- slurm-devel
- slurm-perlapi
- slurm-sjobexit
- slurm-sjstat
- slurm-torque
- service:
name={{item}}
enabled=no
state=stopped
with_items:
- slurmd
- slurmctld
when: is_rhel_compatible

0 comments on commit ddf28c1

Please sign in to comment.