mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-05-20 10:34:30 +00:00
bepasty: Don't remove old system user and group
As removing a system user and group is considered a bad practice. Old unused system accounts are mostly harmless. Tests: - Bepasty functional tests pass. - Installing bepasty and uploading a file works. Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
This commit is contained in:
parent
e48ff1afbc
commit
529bbf77df
@ -91,8 +91,6 @@ def setup(domain_name: str):
|
|||||||
|
|
||||||
# Migrate from old bepasty:bepasty ownership to root:root
|
# Migrate from old bepasty:bepasty ownership to root:root
|
||||||
shutil.chown(CONF_FILE, user='root', group='root')
|
shutil.chown(CONF_FILE, user='root', group='root')
|
||||||
action_utils.run(['deluser', 'bepasty'], check=False)
|
|
||||||
action_utils.run(['delgroup', 'bepasty'], check=False)
|
|
||||||
|
|
||||||
|
|
||||||
@privileged
|
@privileged
|
||||||
@ -151,6 +149,6 @@ def _generate_password():
|
|||||||
|
|
||||||
@privileged
|
@privileged
|
||||||
def uninstall():
|
def uninstall():
|
||||||
"""Remove bepasty user, group and data."""
|
"""Remove data and configuration file."""
|
||||||
shutil.rmtree(DATA_DIR, ignore_errors=True)
|
shutil.rmtree(DATA_DIR, ignore_errors=True)
|
||||||
CONF_FILE.unlink(missing_ok=True)
|
CONF_FILE.unlink(missing_ok=True)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user