Browse Source

Remove functional tests gate for centos7 and workarounds for python2

CentOS 7 job is running with python2, which is no longer supported by
nova. Devstack also dropped it's platform tests for CentOS.

Change-Id: I74b04cf6ecd978bfc5fbf3b2c7484a79d28ae826
tags/1.3.0
Grzegorz Grasza 4 months ago
parent
commit
4aa08a25b8
3 changed files with 8 additions and 46 deletions
  1. +4
    -14
      .zuul.yaml
  2. +0
    -31
      roles/configure-freeipa/tasks/main.yaml
  3. +4
    -1
      scripts/novajoin-install

+ 4
- 14
.zuul.yaml View File

@@ -8,19 +8,20 @@
jobs:
- novajoin-functional:
voting: false
- novajoin-functional-py3:
voting: false

- job:
name: novajoin-functional
description: |
Run functional tests for novajoin.
parent: devstack-tox-base
nodeset: devstack-single-node-centos-7
nodeset: devstack-single-node-fedora-latest
pre-run: playbooks/functional/pre.yaml
run: playbooks/functional/run.yaml
post-run: playbooks/functional/post.yaml
vars:
tox_envlist: functional-py3
bindep_profile: test py3
python_version: 3
devstack_services:
# FreeIPA is using Apache with TLS
tls-proxy: false
@@ -46,14 +47,3 @@
# Disable Cinder services
c-bak: false
c-vol: false

- job:
name: novajoin-functional-py3
description: |
Run functional tests under Python 3.
parent: novajoin-functional
nodeset: devstack-single-node-fedora-latest
vars:
tox_envlist: functional-py3
bindep_profile: test py3
python_version: 3

+ 0
- 31
roles/configure-freeipa/tasks/main.yaml View File

@@ -1,21 +1,3 @@
- name: Find Paramiko ssh_gss.py
command: python -c "from paramiko import ssh_gss; print(ssh_gss.__file__.rstrip('c'))"
register: ssh_gss_file

- name: Patch Paramiko (https://github.com/paramiko/paramiko/pull/1311)
replace:
path: '{{ ssh_gss_file.stdout }}'
regexp: 'GSS_EXCEPTIONS = \(gssapi.GSSException,\)'
replace: 'GSS_EXCEPTIONS = ()'
become: true

- name: Patch Paramiko (https://github.com/paramiko/paramiko/pull/1311)
replace:
path: '{{ ssh_gss_file.stdout }}'
regexp: 'GSS_AUTH_AVAILABLE = True'
replace: 'GSS_AUTH_AVAILABLE = False'
become: true

- name: Install paramiko to patch it (Python3)
pip:
name: paramiko
@@ -100,16 +82,3 @@
--forwarder={{ unbound_primary_nameserver_v4 | default('1.1.1.1') }}
--forwarder={{ unbound_secondary_nameserver_v4 | default('8.8.8.8') }}
become: true

- name: Remove system python-decorator package which conflicts with devstack
command: rpm -e --nodeps python-decorator-3.4.0-3.el7.noarch
become: true
ignore_errors: yes
when: python_version is not defined

- name: Install the latest decorator module for devstack
pip:
name: decorator
state: forcereinstall
become: true
when: python_version is not defined

+ 4
- 1
scripts/novajoin-install View File

@@ -237,13 +237,16 @@ def install(opts):
join_config.write(f)

logger.info('Importing IPA metadata')
#NOTE(xek): pass in os.environ, because ipautils overwrites PATH otherwise
(stdout, stderr, returncode) = run(
['glance',
'--os-image-api-version',
'2',
'md-namespace-import',
'--file',
'/usr/share/novajoin/freeipa.json'], raiseonerr=False)
'/usr/share/novajoin/freeipa.json'],
raiseonerr=False,
env=os.environ)
if returncode != 0:
logger.error('Adding IPA metadata failed: %s' % stderr)



Loading…
Cancel
Save