better (more verbose;clearer; uptodate) output for gitlab:incoming_email:check
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
I was trying to setup incoming_email in my gitlab-omnibus-8.6.2ce instance, and it didn't work.
Following the documentation I ran sudo gitlab-rake gitlab:incoming_email:check after reconfiguring my gitlab.rb and got:
$ sudo gitlab-rake gitlab:incoming_email:check
Checking Reply by email ...
Address formatted correctly? ... yes
IMAP server credentials are correct? ... no
Try fixing it:
Check that the information in config/gitlab.yml is correct
For more information see:
doc/incoming_email/README.md
Please fix the error above and rerun the checks.
Init.d configured correctly? ... skipped (omnibus-gitlab has no init script)
MailRoom running? ... can't check because of previous errors
Checking Reply by email ... Finished
$
Now the output above was not really helpful (apart from confirming that it didn't work).
As an omnibus user, I never before touched the files config/gitlab.yml (nor did I know it existed). Similarily, I only ever consulted ${external_url}/help/incoming_email/README and didn't know about a file doc/incoming_email/README.md.
(Btw, searching my harddisk I find that these files indeed exist as /var/opt/gitlab/gitlab-rails/etc/gitlab.yml resp /opt/gitlab/embedded/service/gitlab-rails/doc/incoming_email/README.md)
So here's a few suggestions:
- when refering to files, please use their full path
- even better, (additionally) refer to the resources the user usually deals with (e.g.
/etc/gitlab/gitlab.rb, online documentation of the running instance,...) - print out the relevant configuration in use, rather than letting the user parse the config-file again.
Something like:
$ sudo gitlab-rake gitlab:incoming_email:check
Checking Reply by email ...
Address formatted correctly? ... yes
IMAP server credentials are correct? ... no
* email = "gitlab-incoming"
* password = "************"
* host = "mail.example.com"
* port = 143
* ssl = false
* startttls = true
* mailbox_name = "inbox"
Try fixing it:
Check that the information in /var/opt/gitlab/gitlab-rails/etc/gitlab.yml is correct.
For more information see
${external_url}/help/incoming_email/README or
/opt/gitlab/embedded/service/gitlab-rails/doc/incoming_email/README.md
Please fix the error above and rerun the checks.
[...]