mib1185 commented on a change in pull request #5110:
URL: https://github.com/apache/cloudstack/pull/5110#discussion_r663464728
##########
File path: python/lib/cloudutils/utilities.py
##########
@@ -134,17 +134,23 @@ def __init__(self):
self.distro = "Ubuntu"
else:
raise UnknownSystemException(distributor)
- else:
+ elif os.path.exists("/etc/os-release"):
+ version = open("/etc/os-release").readline()
+ if version.find("openSUSE") != -1:
+ self.distro = "openSUSE"
+ else:
+ raise UnknownSystemException(distributor)
Review comment:
```suggestion
else:
distributor=`grep -e "^NAME=" /etc/os-release | awk -F\"
'{print $2}'` or None
raise UnknownSystemException(distributor)
```
or get `distributor` from `/etc/os-release`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]