Skip to content
Snippets Groups Projects
Commit fdc90e12 authored by Chris Hines's avatar Chris Hines
Browse files

Merge branch 'master' of github.com:l1ll1/ansible_cluster_in_a_box

parents 85ab9949 167a9ead
No related branches found
No related tags found
No related merge requests found
---
- include_vars: "{{ ansible_os_family }}.yml"
- name: install lua
yum: name={{ item }} state=installed
with_items:
- lua
- lua-filesystem
- lua-posix
sudo: true
when: ansible_os_family == 'RedHat'
- name: install lua
apt: name={{ item }} state=installed
with_items:
- lua5.2
- lua5.2
- lua-filesystem
- lua-bitop
- lua-posix
- liblua5.2-0
- liblua5.2-dev
- tcl
sudo: true
when: ansible_os_family == 'Debian'
- name: link bash
file: src={{ soft_dir }}/lmod/lmod/init/bash dest=/etc/profile.d/lmod.sh state=link
sudo: true
- name: link csh
file: src={{ soft_dir }}/lmod/lmod/init/cshrc dest=/etc/profile.d/lmod.csh state=link
sudo: true
---
lua_include: /usr/include/lua5.2
---
lua_include: /usr/local
---
source_dir: /tmp
soft_dir: /usr/local
lmod_version: 5.8.6
---
- name: stat usrlocal
stat: path={{ dest }}
register: stat_usrlocal
- name: mv
command: mv /usr/local /usr/local_old
when: stat_usrlocal.stat.isdir == True
sudo: true
- name: link
file: src="{{ src }}" dest="{{ dest }}" state=link
sudo: true
---
- include_vars: "{{ ansible_os_family }}.yml"
- name: install lua
yum: name={{ item }} state=installed
with_items:
- lua
- lua-filesystem
- lua-posix
sudo: true
when: ansible_os_family == 'RedHat'
- name: install lua
apt: name={{ item }} state=installed
with_items:
- lua5.2
- lua5.2
- lua-filesystem
- lua-bitop
- lua-posix
- liblua5.2-0
- liblua5.2-dev
- tcl
sudo: true
when: ansible_os_family == 'Debian'
- name: Download LMOD
get_url:
url=http://downloads.sourceforge.net/project/lmod/Lmod-{{ lmod_version }}.tar.bz2
dest={{source_dir}}/Lmod-{{ lmod_version }}.tar.bz2
mode=0444
- name: Uncompress LMOD
unarchive:
src={{ source_dir }}/Lmod-{{ lmod_version }}.tar.bz2
dest={{ source_dir }}
copy=no
creates={{source_dir}}/Lmod-{{ lmod_version }}/README
- name: Compile and install Lmod
shell: cd {{ source_dir }}/Lmod-{{ lmod_version }}; ./configure --prefix={{ soft_dir }} --with-mpathSearch=YES --with-caseIndependentSorting=YES && make install LUA_INCLUDE={{ lua_include }}
args:
creates: "{{ soft_dir }}/lmod/{{ lmod_version }}"
sudo: true
---
lua_include: /usr/include/lua5.2
---
lua_include: /usr/local
---
source_dir: /tmp
soft_dir: /usr/local
lmod_version: 5.8.6
...@@ -13,6 +13,7 @@ ...@@ -13,6 +13,7 @@
- libcgmanager0 - libcgmanager0
sudo: true sudo: true
when: ansible_os_family == "Debian" when: ansible_os_family == "Debian"
sudo: true
- name: config cgroup.conf file - name: config cgroup.conf file
template: dest={{ slurm_dir }}/etc/cgroup.conf src=cgroup.conf.j2 mode=644 template: dest={{ slurm_dir }}/etc/cgroup.conf src=cgroup.conf.j2 mode=644
......
...@@ -87,6 +87,7 @@ ...@@ -87,6 +87,7 @@
- mysql-client - mysql-client
- python-mysqldb - python-mysqldb
- libmysqlclient-dev - libmysqlclient-dev
- lua5.2
when: ansible_os_family == "Debian" when: ansible_os_family == "Debian"
- include: installMungeFromSource.yml - include: installMungeFromSource.yml
...@@ -151,7 +152,7 @@ ...@@ -151,7 +152,7 @@
delegate_to: "{{ slurmctrl }}" delegate_to: "{{ slurmctrl }}"
run_once: true run_once: true
sudo: true sudo: true
when: slurm_lua when: slurm_lua is defined
- include: installCgroup.yml - include: installCgroup.yml
- include: installNhc.yml - include: installNhc.yml
......
...@@ -46,7 +46,7 @@ ReturnToService=1 ...@@ -46,7 +46,7 @@ ReturnToService=1
TaskPlugin=task/cgroup TaskPlugin=task/cgroup
#TaskPlugin=task/affinity #TaskPlugin=task/affinity
#TaskPlugin=task/affinity,task/cgroup #TaskPlugin=task/affinity,task/cgroup
{% if slurm_lua %} {% if slurm_lua is defined %}
JobSubmitPlugins=lua JobSubmitPlugins=lua
{% endif %} {% endif %}
OverTimeLimit=1 OverTimeLimit=1
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment