]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
Move constants to opsys module
authorZack Cerza <zack@redhat.com>
Fri, 20 May 2016 21:42:18 +0000 (15:42 -0600)
committerZack Cerza <zack@redhat.com>
Fri, 3 Jun 2016 21:02:49 +0000 (15:02 -0600)
Signed-off-by: Zack Cerza <zack@redhat.com>
teuthology/orchestra/opsys.py
teuthology/packaging.py

index 34cee5f3d1b7e00d5425c9f5b0f56d792e74c04d..4831e20a840032fcb43b7473ad3459fa5b5a54a9 100644 (file)
@@ -1,6 +1,29 @@
 import ast
 import re
 
+DISTRO_CODENAME_MAP = {
+    "ubuntu": {
+        "16.04": "xenial",
+        "14.04": "trusty",
+        "12.04": "precise",
+        "15.04": "vivid",
+    },
+    "debian": {
+        "7": "wheezy",
+        "8": "jessie",
+    },
+}
+
+DEFAULT_OS_VERSION = dict(
+    ubuntu="14.04",
+    fedora="20",
+    centos="7.0",
+    opensuse="12.2",
+    sles="11-sp2",
+    rhel="7.0",
+    debian='7.0'
+)
+
 
 class OS(object):
     """
index a4cafbb942f653d485e04d47d5363cb7ead173b4..0ca8e3205b7d54e777f1644eefc7b0003d7fb2c4 100644 (file)
@@ -8,6 +8,7 @@ from cStringIO import StringIO
 from .config import config
 from .contextutil import safe_while
 from .exceptions import VersionNotFoundError
+from .orchestra.opysys import DISTRO_CODENAME_MAP, DEFAULT_OS_VERSION
 
 log = logging.getLogger(__name__)
 
@@ -28,29 +29,6 @@ _SERVICE_MAP = {
     'httpd': {'deb': 'apache2', 'rpm': 'httpd'}
 }
 
-DISTRO_CODENAME_MAP = {
-    "ubuntu": {
-        "16.04": "xenial",
-        "14.04": "trusty",
-        "12.04": "precise",
-        "15.04": "vivid",
-    },
-    "debian": {
-        "7": "wheezy",
-        "8": "jessie",
-    },
-}
-
-DEFAULT_OS_VERSION = dict(
-    ubuntu="14.04",
-    fedora="20",
-    centos="7.0",
-    opensuse="12.2",
-    sles="11-sp2",
-    rhel="7.0",
-    debian='7.0'
-)
-
 
 def get_package_name(pkg, rem):
     """