Explorar o código

Merged in ArinToaca/coriolis-core/ol6-osmorph (pull request #124)

Fix /etc/os-release parsing.

Approved-by: Nashwan Azhari <nazhari@cloudbasesolutions.com>
Arin Toaca %!s(int64=7) %!d(string=hai) anos
pai
achega
83845c40bd
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      coriolis/utils.py

+ 2 - 0
coriolis/utils.py

@@ -112,6 +112,8 @@ def parse_os_release(ssh):
         if "=" not in line:
             continue
         k, v = line.split("=")
+        k = k.strip()
+        v = v.strip()
         info[k] = v.strip('"')
     if info.get("ID") and info.get("VERSION_ID"):
         return (info.get("ID"), info.get("VERSION_ID"))