Skip to content

Commit 968ab8b

Browse files
authored
Environment module system now optional, but enabled by default (#88)
* Environment module system now optional, but enabled by default The use case is when you want to use a different module system to the one we supply or want to run without one enitrely. * Use Steve's suggestion See: #88 (review)
1 parent af5ef65 commit 968ab8b

File tree

5 files changed

+7
-4
lines changed

5 files changed

+7
-4
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@ package in the image.
3737

3838
`openhpc_login_only_nodes`: Optional. If using "configless" mode specify the name of an ansible group containing nodes which are login-only nodes (i.e. not also control nodes), if required. These nodes will run `slurmd` to contact the control node for config.
3939

40+
`openhpc_module_system_install`: Optional, default true. Whether or not to install an environment module system. If true, lmod will be installed. If false, You can either supply your own module system or go without one.
41+
4042
### slurm.conf
4143

4244
`openhpc_slurm_partitions`: list of one or more slurm partitions. Each partition may contain the following values:

defaults/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,3 +51,4 @@ ohpc_release_repos:
5151
openhpc_slurm_configless: false
5252
openhpc_munge_key: ''
5353
openhpc_login_only_nodes: ''
54+
openhpc_module_system_install: true

tasks/install.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@
3939
set_fact:
4040
openhpc_slurm_pkglist: "{{ openhpc_slurm_pkglist | default([]) + item.value }}"
4141
loop: "{{ ohpc_slurm_packages | dict2items }}"
42-
when: "openhpc_enable.get(item.key, false)"
42+
when: openhpc_enable.get(item.key, false)
4343

4444
- name: Install required slurm packages
4545
yum:
46-
name: "{{ openhpc_slurm_pkglist }}"
46+
name: "{{ openhpc_slurm_pkglist | reject('eq', '') }}"
4747
when: openhpc_slurm_pkglist | default(false, true)
4848

4949
- name: Install packages from openhpc_packages variable

vars/ohpc-1.3

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ ohpc_slurm_packages:
1414
- "munge-ohpc"
1515
- "slurm-slurmd-ohpc"
1616
- "slurm-example-configs-ohpc"
17-
- "lmod-ohpc"
17+
- "{{ 'lmod-ohpc' if openhpc_module_system_install else '' }}"
1818
database:
1919
- "slurm-slurmdbd-ohpc"
2020
...

vars/ohpc-2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ ohpc_slurm_packages:
1414
- "munge"
1515
- "slurm-slurmd-ohpc"
1616
- "slurm-example-configs-ohpc"
17-
- "lmod-ohpc"
17+
- "{{ 'lmod-ohpc' if openhpc_module_system_install else '' }}"
1818
database:
1919
- "slurm-slurmdbd-ohpc"
2020
...

0 commit comments

Comments
 (0)