JasperServer邮件设置

1、配置【jasperserver/WEB-INF/js.quartz.properties】文件
report.scheduler.mail.sender.host=smtp.163.com
report.scheduler.mail.sender.username=username
report.scheduler.mail.sender.password=password
[email protected]

2、邮箱通过SMTP发送是要经过验证的,配置【jasperserver/WEB-INF/applicationContext-report-scheduling.xml】文件,找到以下的Bean配置修改mail.smtp.auth为true
    <bean id="reportSchedulerMailSender" class="org.springframework.mail.javamail.JavaMailSenderImpl">
        <property name="host" value="${report.scheduler.mail.sender.host}"/>
        <property name="username" value="${report.scheduler.mail.sender.username}"/>
        <property name="password" value="${report.scheduler.mail.sender.password}"/>
        <property name="protocol" value="${report.scheduler.mail.sender.protocol}"/>
        <property name="port" value="${report.scheduler.mail.sender.port}"/>
        <property name="javaMailProperties">
            <props>
                <prop key="mail.smtp.auth">true</prop>
            </props>
        </property>
    </bean>

你可能感兴趣的:(server)