mirror of
https://git.selfprivacy.org/SelfPrivacy/selfprivacy-rest-api.git
synced 2024-11-19 16:49:14 +00:00
10 lines
274 B
Python
10 lines
274 B
Python
#!/usr/bin/env python3
|
|
"""Various utility functions"""
|
|
|
|
|
|
def get_domain():
|
|
"""Get domain from /var/domain without trailing new line"""
|
|
with open("/var/domain", "r", encoding="utf-8") as domain_file:
|
|
domain = domain_file.readline().rstrip()
|
|
return domain
|