Skip to content

Commit

Permalink
travis-ci/gitlab-ci: add CentOS 8
Browse files Browse the repository at this point in the history
Added build + test jobs in GitLab-CI and build + test + deploy jobs on
Travis-CI for CentOS 8.

Updated testing dependencies in the RPM spec to follow the new Python 2
package naming scheme that was introduced in CentOS 8: it uses
'python2-' prefix rather then 'python-'.

CentOS 8 does not provide python2-gevent and python2-greenlet packages,
so they were pushed to https://packagecloud.io/packpack/backports
repository. This repository is enabled in our build image
(packpack/packpack:el-8) by default. Those dependencies are build-time,
so nothing was changed for a user. The source RPM packages were gathered
from https://cbs.centos.org.

Disabled app-tap/pwd.test.lua on CentOS 8 due to systemd-nss issue,
which was not worked around properly. Filed #4592 to resolved it in the
future.

Eliminated libunwind runtime dependency (and libunwind-devel build
dependency) on CentOS 8, because the base system does not provide it.
fiber.info() backtraces and printing of a backtrace after a crash will
not be available on this system. Hopefully we'll fix it in the future,
filed #4611 on this.

Closes #4543
  • Loading branch information
avtikhon authored and Totktonada committed Nov 8, 2019
1 parent 41359c8 commit ef906dc
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .gitlab-ci.yml
Expand Up @@ -152,6 +152,12 @@ centos_7:
OS: 'el'
DIST: '7'

centos_8:
<<: *deploy_test_definition
variables:
OS: 'el'
DIST: '8'

fedora_28:
<<: *deploy_test_definition
variables:
Expand Down
3 changes: 3 additions & 0 deletions .travis.yml
Expand Up @@ -43,6 +43,9 @@ jobs:
- name: "CentOS 7 build + test + deploy RPM"
env: OS=el DIST=7
if: branch = "master"
- name: "CentOS 8 build + test + deploy RPM"
env: OS=el DIST=8
if: branch = "master"
- name: "Fedora 28 build + test + deploy RPM"
env: OS=fedora DIST=28
if: branch = "master"
Expand Down
17 changes: 15 additions & 2 deletions rpm/tarantool.spec
Expand Up @@ -44,7 +44,14 @@ Requires(preun): chkconfig
Requires(preun): initscripts
%endif

%bcond_without backtrace # enabled by default
%if 0%{?rhel} >= 8
# gh-4611: Disable backtraces on CentOS 8 by default due to lack
# of libunwind package in the base system.
%bcond_with backtrace
%else
# Enable backtraces by default.
%bcond_without backtrace
%endif

%if %{with backtrace}
BuildRequires: libunwind-devel
Expand All @@ -63,12 +70,18 @@ BuildRequires: libunwind-devel
%endif

# For tests
%if (0%{?fedora} >= 22 || 0%{?rhel} >= 7)
%if (0%{?fedora} >= 22 || 0%{?rhel} == 7)
BuildRequires: python >= 2.7
BuildRequires: python-six >= 1.9.0
BuildRequires: python-gevent >= 1.0
BuildRequires: python-yaml >= 3.0.9
%endif
%if 0%{?rhel} >= 8
BuildRequires: python2 >= 2.7
BuildRequires: python2-six >= 1.9.0
BuildRequires: python2-gevent >= 1.0
BuildRequires: python2-yaml >= 3.0.9
%endif

Name: tarantool
# ${major}.${major}.${minor}.${patch}, e.g. 1.6.8.175
Expand Down
11 changes: 11 additions & 0 deletions test/app-tap/pwd.skipcond
@@ -0,0 +1,11 @@
import subprocess

# Disable the test on CentOS 8 until gh-4592 will be resolved.
try:
cmd = ['rpm', '--eval', '%{centos_ver}']
if subprocess.check_output(cmd).strip() == '8':
self.skip = 1
except:
pass

# vim: set ft=python:

0 comments on commit ef906dc

Please sign in to comment.