mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
apps: people insist on trying to install Nextcloud after creating a user called nextcloud ... So let's check this stupid case
This commit is contained in:
parent
4ed5e1ba20
commit
fc12cb198c
1 changed files with 4 additions and 0 deletions
|
@ -1068,6 +1068,7 @@ def app_install(
|
||||||
)
|
)
|
||||||
from yunohost.regenconf import manually_modified_files
|
from yunohost.regenconf import manually_modified_files
|
||||||
from yunohost.utils.legacy import _patch_legacy_php_versions, _patch_legacy_helpers
|
from yunohost.utils.legacy import _patch_legacy_php_versions, _patch_legacy_helpers
|
||||||
|
from yunohost.user import user_list
|
||||||
|
|
||||||
# Check if disk space available
|
# Check if disk space available
|
||||||
if free_space_in_directory("/") <= 512 * 1000 * 1000:
|
if free_space_in_directory("/") <= 512 * 1000 * 1000:
|
||||||
|
@ -1091,6 +1092,9 @@ def app_install(
|
||||||
|
|
||||||
app_id = manifest["id"]
|
app_id = manifest["id"]
|
||||||
|
|
||||||
|
if app_id in user_list()["users"].keys():
|
||||||
|
raise YunohostValidationError(f"There is already a YunoHost user called {app_id} ...", raw_msg=True)
|
||||||
|
|
||||||
# Check requirements
|
# Check requirements
|
||||||
for name, passed, values, err in _check_manifest_requirements(
|
for name, passed, values, err in _check_manifest_requirements(
|
||||||
manifest, action="install"
|
manifest, action="install"
|
||||||
|
|
Loading…
Add table
Reference in a new issue