Fixed issues in rspamd script
This commit is contained in:
@@ -103,6 +103,17 @@ def dist_name():
|
||||
return dist_info()[0].lower()
|
||||
|
||||
|
||||
def is_dist_debian_based() -> (bool, str):
|
||||
"""Check if current OS is Debian based or not."""
|
||||
status, codename = exec_cmd("lsb_release -c -s")
|
||||
codename = codename.lower()
|
||||
return codename in [
|
||||
"bionic", "bookworm", "bullseye", "buster",
|
||||
"focal", "jammy", "jessie", "sid", "stretch",
|
||||
"trusty", "wheezy", "xenial"
|
||||
], codename
|
||||
|
||||
|
||||
def mkdir(path, mode, uid, gid):
|
||||
"""Create a directory."""
|
||||
if not os.path.exists(path):
|
||||
|
||||
Reference in New Issue
Block a user