Gate: Deploy HWE kernel on ubuntu hosts

This PS deploys the HWE kernel on Ubuntu Hosts, which is required
for CephFS:
 * https://github.com/kubernetes-incubator/external-storage/issues/345

Change-Id: I2ebd46eadf5a4c7a857d42302f388511691ab0db
This commit is contained in:
portdirect 2018-01-08 20:19:03 -05:00 committed by Pete Birley
parent abd7e78c65
commit 13852ceee4
3 changed files with 82 additions and 0 deletions

View File

@ -99,6 +99,7 @@
- job:
name: openstack-helm-infra
pre-run:
- tools/gate/playbooks/osh-infra-upgrade-host.yaml
- tools/gate/playbooks/osh-infra-deploy-docker.yaml
- tools/gate/playbooks/osh-infra-build.yaml
- tools/gate/playbooks/osh-infra-pull-images.yaml

View File

@ -0,0 +1,39 @@
# Copyright 2017 The Openstack-Helm Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
- hosts: all
vars_files:
- vars.yaml
vars:
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
gather_facts: False
become: yes
roles:
- deploy-python
tags:
- deploy-python
- hosts: all
vars_files:
- vars.yaml
vars:
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
gather_facts: True
become: yes
roles:
- upgrade-host
- start-zuul-console
tags:
- upgrade-host
- start-zuul-console

View File

@ -0,0 +1,42 @@
# Copyright 2017 The Openstack-Helm Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
- name: Upgrade to HWE kernel on Ubuntu Hosts
when: ansible_distribution == 'Ubuntu'
block:
- name: Deploy HWE kernel on Ubuntu Hosts
include_role:
name: deploy-package
tasks_from: dist
vars:
packages:
deb:
- linux-generic-hwe-16.04
- name: Reboot Host following kernel upgrade
shell: sleep 2 && reboot
sudo: yes
async: 30
poll: 0
ignore_errors: true
args:
executable: /bin/bash
- name: Wait for hosts to come up following reboot
wait_for:
host: '{{ hostvars[item].ansible_host }}'
port: 22
state: started
delay: 30
timeout: 120
with_items: '{{ play_hosts }}'
connection: local