From: Andrey1994 Date: Wed, 22 Mar 2017 18:34:45 +0000 (+0300) Subject: [RM-19301] add Virtuozzo Linux support X-Git-Tag: v1.5.38~4^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=20361ac3fcbb94fb5e354e1f4e182f96d42e684c;p=ceph-deploy.git [RM-19301] add Virtuozzo Linux support Signed-off-by: Andrey1994 --- diff --git a/ceph_deploy/hosts/__init__.py b/ceph_deploy/hosts/__init__.py index f5d8541..a96e614 100644 --- a/ceph_deploy/hosts/__init__.py +++ b/ceph_deploy/hosts/__init__.py @@ -66,9 +66,9 @@ def get(hostname, module.normalized_name = _normalized_distro_name(distro_name) module.normalized_release = _normalized_release(release) module.distro = module.normalized_name - module.is_el = module.normalized_name in ['redhat', 'centos', 'fedora', 'scientific', 'oracle'] + module.is_el = module.normalized_name in ['redhat', 'centos', 'fedora', 'scientific', 'oracle', 'virtuozzo'] module.is_rpm = module.normalized_name in ['redhat', 'centos', - 'fedora', 'scientific', 'suse', 'oracle'] + 'fedora', 'scientific', 'suse', 'oracle', 'virtuozzo'] module.is_deb = not module.is_rpm module.release = release module.codename = codename @@ -97,6 +97,7 @@ def _get_distro(distro, fallback=None, use_rhceph=False): 'redhat': centos, 'fedora': fedora, 'suse': suse, + 'virtuozzo' : centos } if distro == 'redhat' and use_rhceph: @@ -119,6 +120,8 @@ def _normalized_distro_name(distro): return 'centos' elif distro.startswith('linuxmint'): return 'ubuntu' + elif distro.startswith('virtuozzo'): + return 'virtuozzo' return distro diff --git a/ceph_deploy/hosts/centos/install.py b/ceph_deploy/hosts/centos/install.py index c95d746..49e9f8a 100644 --- a/ceph_deploy/hosts/centos/install.py +++ b/ceph_deploy/hosts/centos/install.py @@ -11,7 +11,7 @@ NON_SPLIT_PACKAGES = ['ceph-osd', 'ceph-mon', 'ceph-mds'] def rpm_dist(distro): - if distro.normalized_name in ['redhat', 'centos', 'scientific', 'oracle'] and distro.normalized_release.int_major >= 6: + if distro.normalized_name in ['redhat', 'centos', 'scientific', 'oracle', 'virtuozzo'] and distro.normalized_release.int_major >= 6: return 'el' + distro.normalized_release.major return 'el6' @@ -35,7 +35,7 @@ def repository_url_part(distro): if distro.normalized_release.int_major >= 6: if distro.normalized_name == 'redhat': return 'rhel' + distro.normalized_release.major - if distro.normalized_name in ['centos', 'scientific', 'oracle']: + if distro.normalized_name in ['centos', 'scientific', 'oracle', 'virtuozzo']: return 'el' + distro.normalized_release.major return 'el6' diff --git a/ceph_deploy/hosts/remotes.py b/ceph_deploy/hosts/remotes.py index d0b52f6..2f3e4c8 100644 --- a/ceph_deploy/hosts/remotes.py +++ b/ceph_deploy/hosts/remotes.py @@ -33,6 +33,8 @@ def platform_information(_linux_distribution=None): codename = major if not codename and 'oracle' in distro.lower(): # this could be an empty string in Oracle linux codename = 'oracle' + if not codename and 'virtuozzo linux' in distro.lower(): # this could be an empty string in Virtuozzo linux + codename = 'virtuozzo' return ( str(distro).rstrip(),