diff --git a/modules/joex/src/main/resources/reference.conf b/modules/joex/src/main/resources/reference.conf index e4b1a38c..a9b76e71 100644 --- a/modules/joex/src/main/resources/reference.conf +++ b/modules/joex/src/main/resources/reference.conf @@ -31,6 +31,12 @@ docspell.joex { password = "" } + # Enable or disable debugging for e-mail related functionality. This + # applies to both sending and receiving mails. For security reasons + # logging is not very extensive on authentication failures. Setting + # this to true, results in a lot of data printed to stdout. + mail-debug = false + send-mail { # This is used as the List-Id e-mail header when mails are sent # from docspell to its users (example: for notification mails). It diff --git a/modules/joex/src/main/scala/docspell/joex/Config.scala b/modules/joex/src/main/scala/docspell/joex/Config.scala index fb6df973..7292e5f9 100644 --- a/modules/joex/src/main/scala/docspell/joex/Config.scala +++ b/modules/joex/src/main/scala/docspell/joex/Config.scala @@ -22,7 +22,8 @@ case class Config( textAnalysis: TextAnalysisConfig, convert: ConvertConfig, sendMail: MailSendConfig, - files: Files + files: Files, + mailDebug: Boolean ) object Config { diff --git a/modules/joex/src/main/scala/docspell/joex/JoexAppImpl.scala b/modules/joex/src/main/scala/docspell/joex/JoexAppImpl.scala index ea11a908..d07ca841 100644 --- a/modules/joex/src/main/scala/docspell/joex/JoexAppImpl.scala +++ b/modules/joex/src/main/scala/docspell/joex/JoexAppImpl.scala @@ -70,7 +70,8 @@ object JoexAppImpl { nodeOps <- ONode(store) joex <- OJoex(client, store) upload <- OUpload(store, queue, cfg.files, joex) - javaEmil = JavaMailEmil(blocker) + javaEmil = + JavaMailEmil(blocker, Settings.defaultSettings.copy(debug = cfg.mailDebug)) sch <- SchedulerBuilder(cfg.scheduler, blocker, store) .withQueue(queue) .withTask(