mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Better handling of the didn't-run-diagnosis-ever-yet case (c.f. also commit for webadmin)
This commit is contained in:
parent
0decb6477e
commit
b5d18d63c7
2 changed files with 5 additions and 0 deletions
|
@ -220,6 +220,7 @@
|
|||
"diagnosis_http_bad_status_code": "Could not reach your server as expected, it returned a bad status code. It might be that another machine answered instead of your server. You should check that you're correctly forwarding port 80, that your nginx configuration is up to date, and that a reverse-proxy is not interfering.",
|
||||
"diagnosis_http_unreachable": "Domain {domain} is unreachable through HTTP from outside.",
|
||||
"diagnosis_unknown_categories": "The following categories are unknown: {categories}",
|
||||
"diagnosis_never_ran_yet": "It looks like this server was setup recently and there's no diagnosis report to show yet. You should start by running a full diagnosis, either from the webadmin or using 'yunohost diagnosis run' from the command line.",
|
||||
"domain_cannot_remove_main": "You cannot remove '{domain:s}' since it's the main domain, you first need to set another domain as the main domain using 'yunohost domain main-domain -n <another-domain>'; here is the list of candidate domains: {other_domains:s}",
|
||||
"domain_cannot_remove_main_add_new_one": "You cannot remove '{domain:s}' since it's the main domain and your only domain, you need to first add another domain using 'yunohost domain add <another-domain.com>', then set is as the main domain using 'yunohost domain main-domain -n <another-domain.com>' and then you can remove the domain '{domain:s}' using 'yunohost domain remove {domain:s}'.'",
|
||||
"domain_cert_gen_failed": "Could not generate certificate",
|
||||
|
|
|
@ -58,6 +58,10 @@ def diagnosis_show(categories=[], issues=False, full=False, share=False):
|
|||
if unknown_categories:
|
||||
raise YunohostError('diagnosis_unknown_categories', categories=", ".join(categories))
|
||||
|
||||
if not os.path.exists(DIAGNOSIS_CACHE):
|
||||
logger.warning(m18n.n("diagnosis_never_ran_yet"))
|
||||
return
|
||||
|
||||
# Fetch all reports
|
||||
all_reports = []
|
||||
for category in categories:
|
||||
|
|
Loading…
Add table
Reference in a new issue