Ok,
I've done some more tests...
When I specify my mail settings in a custom config --
[dspace-src]/dspace/config/production.cfg -- and then install with `ant
update -Dconfig=../../config/production.cfg`, sending mail via DSpace
works fine. The [dspace]/config/dspace.cfg generated by the build/ant
process has these SMTP settings:
# SMTP mail server
mail.server = my.smtp.com
# SMTP mail server authentication username and password (if required)
# mail.server.username =
# mail.server.password =
# SMTP mail server alternate port (defaults to 25)
# mail.server.port =
When I use a stock DSpace config --
[dspace-src]/dspace/config/dspace.cfg -- with a custom build.properties
-- [dspace-src]/production.properties -- and then build with
-Denv=production and install with `ant update`, sending mail via DSpace
errors with javax.mail.AuthenticationFailedException. The
[dspace]/config/dspace.cfg generated by the build/ant process has these
SMTP settings:
# SMTP mail server
mail.server = smtp.serv.cgnet.com
# SMTP mail server authentication username and password (if required)
mail.server.username =
mail.server.password =
# SMTP mail server alternate port (defaults to 25)
mail.server.port = 25
If I comment out the mail.* settings in my production.properties file I
get an error about circular definitions:
BUILD FAILED
/home/aorth/src/git/DSpace/dspace/target/dspace-3.1-build/build.xml:88:
Property mail.server.password was circularly defined.
I think the build.properties way of doing things is a step forward, as
it allows for management of multiple DSpace instances from one code
base, but it's a bit confusing! Also, we're using unauthenticated SMTP,
so these username/password settings are really not useful to us.
Thanks,
Alan
On 05/21/2013 04:45 PM, Alan Orth wrote:
Ok,
I've just reverted to our "all in one" dspace.cfg and emails work
fine. Sounds like there are some issues with my build.properties
(dev.properties and production.properties)...
Alan
On 05/21/2013 03:32 PM, helix84 wrote:
On Tue, May 21, 2013 at 2:08 PM, Alan Orth <[email protected]> wrote:
Here's the full stack trace, including the "Caused by":
https://gist.github.com/alanorth/4e942aa252764a3d87aa/raw/2c4a9ad30f537386cc3bb1c9a885204e949038e2/gistfile1.txt
OK, in this case that didn't tell me anything new.
My mail.* properties from dspace.cfg:
Looks good.
mail.allowed.referrers = cgspace.cgiar.org
I have localhost here, so try this:
mail.allowed.referrers = localhost, cgspace.cgiar.org
But I don't think this is the issue (the error would be different).
We did switch to using build.properties (one for
dev and production) with a common dspace.cfg, though... I will try to
use our old config file maybe...
This sounds like a likely culprit to me. Make sure you didn't comment
out any properties present in the default build.properties. You have
to leave the value empty instead of commenting it out.
Regards,
~~helix84
Compulsory reading: DSpace Mailing List Etiquette
https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette
--
Alan Orth
[email protected]
http://alaninkenya.org
http://mjanja.co.ke
"I have always wished for my computer to be as easy to use as my telephone; my wish
has come true because I can no longer figure out how to use my telephone." -Bjarne
Stroustrup, inventor of C++
------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
List Etiquette: https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette