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

Merge branch 'upgrade' into 'master'

Upgrade

See merge request !164

Former-commit-id: 8e2c23ba
parents 2293101c 4aba2730
No related branches found
No related tags found
No related merge requests found
......@@ -2,24 +2,24 @@
[monashhpc_base]
name=MonashHPC base repository mirrored to control the update process
baseurl=https://consistency0/centos/$releasever/os/$basearch/
baseurl=https://consistency0/centos-7.4-1708/$releasever/os/$basearch/
enabled=1
sslverify=false
[monashhpc_udpates]
[monashhpc_updates]
name=MonashHPC base repository mirrored to control the update process
baseurl=https://consistency0/centos/$releasever/updates/$basearch/
baseurl=https://consistency0/centos-7.4-1708/$releasever/updates/$basearch/
enabled=1
sslverify=false
[monashhpc_extras]
name=MonashHPC base repository mirrored to control the update process
baseurl=https://consistency0/centos/$releasever/extras/$basearch/
baseurl=https://consistency0/centos-7.4-1708/$releasever/extras/$basearch/
enabled=1
sslverify=false
[monashhpc_centosplus]
name=MonashHPC base repository mirrored to control the update process
baseurl=https://consistency0/centos/$releasever/centosplus/$basearch/
baseurl=https://consistency0/centos-7.4-1708/$releasever/centosplus/$basearch/
enabled=1
sslverify=false
......@@ -2,7 +2,7 @@
[monashhpc_otherstuff]
name=MonashHPC base repository mirrored to control the update process
baseurl=https://consistency0/centos/hpcsystems/$releasever/$basearch/
baseurl=https://consistency0/centos-7.4-1708/hpcsystems/$releasever/$basearch/
enabled=1
sslverify=false
gpgcheck=0
......@@ -4,28 +4,29 @@
lineinfile: dest=/etc/hosts line="118.138.244.7 consistency0"
sudo: true
- name: remove default repos
file:
path: /etc/yum.repos.d/{{ item }}
state: absent
become: true
become_user: root
with_items:
- CentOS-Base.repo
- CentOS-Debuginfo.repo
- CentOS-fasttrack.repo
- CentOS-Sources.repo
- CentOS-Vault.repo
- foreman.repo
- puppetlabs.repo
- rdo-release.repo
- CentOS-CR.repo
- CentOS-Media.repo
- CentOS-OpenStack-kilo.repo
- epel.repo
- monashhpc_mellanox.repo
- epel-testing.repo
when: ansible_os_family == 'RedHat' and ansible_distribution_major_version == "7"
#- name: remove default repos
# file:
# path: /etc/yum.repos.d/{{ item }}
# state: absent
# become: true
# become_user: root
# with_items:
# - CentOS-Base.repo
# - CentOS-Debuginfo.repo
# - CentOS-fasttrack.repo
# - CentOS-Sources.repo
# - CentOS-Vault.repo
# - foreman.repo
# - puppetlabs.repo
# - rdo-release.repo
# - CentOS-CR.repo
# - CentOS-Media.repo
# - CentOS-OpenStack-kilo.repo
# - epel.repo
# - monashhpc_mellanox.repo
# - epel-testing.repo
# when: ansible_os_family == 'RedHat' and ansible_distribution_major_version == "7"
- name: add our repos
copy: src={{ item }} dest=/etc/yum.repos.d/{{ item }}
......@@ -35,6 +36,23 @@
- monashhpc_base.repo
- monashhpc_others.repo
- name: get enabled repos
#shell: yum repolist | grep -v "repo id" | grep -v "Loaded plugins" | head -n -1 | cut -f 1 -d '/' | sed -s 's/\!//'
shell: yum repolist all | grep enabled | cut -f 1 -d '/' | sed -s 's/\!//'
register: repolist
check_mode: no
- name: disable unwanted repos
shell: yum-config-manager --disable {{ item }}
# yum_repository:
# name: "{{ item }}"
# enabled: False
# state: 'absent'
with_items: "{{repolist.stdout_lines|difference(yumenablerepo)}}"
become: true
become_user: root
ignore_errors: true
#- name: Enable epel
# command: yum-config-manager --enable epel
......
......@@ -20,7 +20,7 @@
reboot_now: false
- name: get driver version
command: 'ofed_info | head -n 1 | cut -f 1 -d " "'
command: 'ofed_info -l | head -n 1 | cut -f 1 -d " "'
register: driver_version
ignore_errors: true
check_mode: no
......@@ -76,6 +76,5 @@
when: reboot_now
- name: waiting for server to come back
local_action: wait_for host={{ ansible_host }} state=started port=22 delay=60 timeout=600 search_regex=OpenSSH
sudo: false
wait_for_connection: sleep=60 timeout=600 delay=60
when: reboot_now
......@@ -3,4 +3,4 @@
#MELLANOX_DRIVER_SRC: "{% if ansible_os_family == 'RedHat' %}MLNX_OFED_LINUX-3.1-1.0.3-rhel7.1-x86_64-ext{% elif ansible_os_family == 'Debian' %}MLNX_OFED_LINUX-3.1-1.0.3-ubuntu14.04-x86_64{% endif %}"
#MELLANOX_DRIVER_SRC: "{% if ansible_os_family == 'RedHat' %}MLNX_OFED_LINUX-3.1-1.0.3-rhel7.2-x86_64-ext{% elif ansible_os_family == 'Debian' %}MLNX_OFED_LINUX-3.1-1.0.3-ubuntu14.04-x86_64{% endif %}"
#MELLANOX_DRIVER_SRC: "{% if ansible_os_family == 'RedHat' %}MLNX_OFED_LINUX-3.4-1.0.0.0-rhel7.2-x86_64{% elif ansible_os_family == 'Debian' %}MLNX_OFED_LINUX-3.1-1.0.3-ubuntu14.04-x86_64{% endif %}"
MELLANOX_DRIVER_SRC: "{% if ansible_os_family == 'RedHat' %}MLNX_OFED_LINUX-3.4-2.1.8.0-rhel7.3-x86_64{% elif ansible_os_family == 'Debian' %}MLNX_OFED_LINUX-3.1-1.0.3-ubuntu14.04-x86_64{% endif %}"
MELLANOX_DRIVER_SRC: "{% if ansible_os_family == 'RedHat' %}MLNX_OFED_LINUX-4.2-1.2.0.0-rhel7.4-x86_64{% elif ansible_os_family == 'Debian' %}MLNX_OFED_LINUX-3.1-1.0.3-ubuntu14.04-x86_64{% endif %}"
......@@ -17,20 +17,32 @@
become_user: root
when: ansible_os_family=="RedHat"
- name: yum upgrade
yum: name=* state=latest disablerepo={{ yumdisablerepo|join(',') }} enablerepo={{ yumenablerepo|join(',') }}
become: true
become_user: root
when: ansible_os_family=="RedHat" and yumdisablerepo is defined
- name: yum upgrade
yum: name=* state=latest
become: true
become_user: root
when: ansible_os_family=="RedHat"
when: ansible_os_family=="RedHat" and yumdisablerepo is undefined
- name: install kernel-devel
yum: name=kernel-devel state=latest disablerepo={{ yumdisablerepo|join(',') }} enablerepo={{ yumenablerepo|join(',') }}
become: true
become_user: root
when: ansible_os_family=="RedHat" and yumdisablerepo is defined
- name: install kernel-devel
yum: name=kernel-devel state=latest
become: true
become_user: root
when: ansible_os_family=="RedHat"
when: ansible_os_family=="RedHat" and yumdisablerepo is undefined
- name: get kernel-devel version
shell: rpm -q kernel-devel | cut -f 3,4 -d "-"
shell: rpm -q kernel-devel | cut -f 3,4 -d "-" | sort | tail -n 1
register: rpm_q_output
when: ansible_os_family=="RedHat"
check_mode: no
......
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