diff --git a/roles/lustre-client/tasks/main.yml b/roles/lustre-client/tasks/main.yml new file mode 100644 index 0000000000000000000000000000000000000000..8d7cf2572c4f3ddd8283e134a199e7ad4a4fc1ee --- /dev/null +++ b/roles/lustre-client/tasks/main.yml @@ -0,0 +1,21 @@ +--- +- include_vars: "{{ ansible_distribution }}_{{ ansible_distirubtion_major_version }}.yaml" + +lustre_pkgs: + - lustre-client-modules-2.7.0-3.10.0_229.14.1.el7.x86_64.x86_64.rpm + - lustre-client-2.7.0-3.10.0_229.14.1.el7.x86_64.x86_64.rpm + +- name: copy rpms + copy: dest=/tmp/ src={{ item }} + with_items: + {{ lustre_pkgs }} + +- name: install rpms + yum: name= /tmp/{{ item }} + sudo: true + with_tiems: + {{ lustre_pkgs }} + +- name: "Mount lustre filesystems" + mount: name="{{ item.mntpt }}" src= "{{ item.servers }}"/"{{ item.src }}" state="mounted" fstype="lustre" opts="_netdev,flock 0 0" + sudo: true diff --git a/roles/lustre-client/vars/CentOS_7.yaml b/roles/lustre-client/vars/CentOS_7.yaml new file mode 100644 index 0000000000000000000000000000000000000000..762d8c74619a6eeb819d18bdefd9d379c705a9a4 --- /dev/null +++ b/roles/lustre-client/vars/CentOS_7.yaml @@ -0,0 +1,5 @@ +--- +lustre_pkgs: + - lustre-client-modules-2.7.0-3.10.0_229.14.1.el7.x86_64.x86_64.rpm + - lustre-client-2.7.0-3.10.0_229.14.1.el7.x86_64.x86_64.rpm +