[#59] add default alarm feature
This commit is contained in:
parent
0f271a1204
commit
29b24254d7
29
.env
29
.env
|
@ -32,27 +32,30 @@ HBASE_PORT=2181
|
|||
|
||||
WEB_DEBUG_LEVEL=INFO
|
||||
|
||||
BATCH_ENABLE=false
|
||||
BATCH_SERVER_IP=127.0.0.127
|
||||
BATCH_ENABLE=true
|
||||
BATCH_SERVER_IP=127.0.0.1
|
||||
BATCH_FLINK_SERVER=pinpoint-flink-jobmanager
|
||||
|
||||
CONFIG_SHOW_APPLICATIONSTAT=true
|
||||
|
||||
#mysql information required
|
||||
JDBC_DRIVER=com.mysql.jdbc.Driver
|
||||
JDBC_URL=jdbc:mysql://pinpoint-mysql:3306/pinpoint?characterEncoding=UTF-8
|
||||
JDBC_USERNAME=admin
|
||||
JDBC_PASSWORD=admin
|
||||
MAIL_HOST=stmp.test.com
|
||||
MAIL_PORT=123
|
||||
MAIL_USERNAME=user
|
||||
MAIL_PASSWORD=pass
|
||||
MAIL_PROPERTIES_MAIL_TRANSPORT_PROTOCOL=smtp
|
||||
MAIL_PROPERTIES_MAIL_SMTP_AUTH=true
|
||||
MAIL_PROPERTIES_MAIL_SMTP_PORT=587
|
||||
MAIL_PROPERTIES_MAIL_SMTP_FROM=test@example.com
|
||||
MAIL_PROPERTIES_MAIL_STARTTLS_ENABLE=true
|
||||
MAIL_PROPERTIES_MAIL_STARTTLS_REQUIRED=true
|
||||
MAIL_PROPERTIES_MAIL_DEBUG=false
|
||||
|
||||
#mail server information required
|
||||
MAIL_SERVER_URL=smtp.gmail.com
|
||||
MAIL_SERVER_PORT=587
|
||||
MAIL_SERVER_USERNAME=username
|
||||
MAIL_SERVER_PASSWORD=password
|
||||
MAIL_SENDER_ADDRESS=pinpoint_operator@pinpoint.com
|
||||
MAIL_TRANSPORT_PROTOCOL=smtp
|
||||
MAIL_SMTP_PORT=25
|
||||
MAIL_SMTP_AUTH=false
|
||||
MAIL_SMTP_STARTTLS_ENABLE=false
|
||||
MAIL_SMTP_STARTTLS_REQUIRED=false
|
||||
MAIL_DEBUG=false
|
||||
|
||||
|
||||
### Pinpoint-Collector
|
||||
|
|
|
@ -90,6 +90,11 @@ Pinpoint-Flink server is running on [port 8081](http://localhost:8081/#/submit).
|
|||
Submit the jar file with *com.navercorp.pinpoint.flink.StatStreamingVer2Job* in entry class as below image.
|
||||
|
||||
![Pinpoint](https://github.com/naver/pinpoint-docker/blob/master/docs/Pinpoint-Flink%20upload.png)
|
||||
|
||||
### Alarm configuration (optional)
|
||||
|
||||
You can check the [alarm guide document at the homepage](https://naver.github.io/pinpoint/alarm.html) for full understanding.
|
||||
But for the docker image, All is set. fillout variables under *#mail server information required* in `.env` file before starting the container
|
||||
|
||||
### Testing QuickStart application
|
||||
|
||||
|
|
|
@ -80,7 +80,7 @@ services:
|
|||
- "9997:9997"
|
||||
- "${WEB_PAGE_PORT:-8080}:8080"
|
||||
environment:
|
||||
- JAVA_OPTS="-Dspring.profiles.active=${SPRING_PROFILES}"
|
||||
- JAVA_OPTS="-Dspring.profiles.active=${SPRING_PROFILES},batch"
|
||||
- SPRING_PROFILES=${SPRING_PROFILES}
|
||||
- CLUSTER_ENABLE=${CLUSTER_ENABLE}
|
||||
- CLUSTER_ZOOKEEPER_ADDRESS=${CLUSTER_ZOOKEEPER_ADDRESS}
|
||||
|
@ -97,17 +97,17 @@ services:
|
|||
- JDBC_URL=${JDBC_URL}
|
||||
- JDBC_USERNAME=${JDBC_USERNAME}
|
||||
- JDBC_PASSWORD=${JDBC_PASSWORD}
|
||||
- MAIL_HOST=${MAIL_HOST}
|
||||
- MAIL_PORT=${MAIL_PORT}
|
||||
- MAIL_USERNAME=${MAIL_USERNAME}
|
||||
- MAIL_PASSWORD=${MAIL_PASSWORD}
|
||||
- MAIL_PROPERTIES_MAIL_TRANSPORT_PROTOCOL=${MAIL_PROPERTIES_MAIL_TRANSPORT_PROTOCOL}
|
||||
- MAIL_PROPERTIES_MAIL_SMTP_AUTH=${MAIL_PROPERTIES_MAIL_SMTP_AUTH}
|
||||
- MAIL_PROPERTIES_MAIL_SMTP_PORT=${MAIL_PROPERTIES_MAIL_SMTP_PORT}
|
||||
- MAIL_PROPERTIES_MAIL_SMTP_FROM=${MAIL_PROPERTIES_MAIL_SMTP_FROM}
|
||||
- MAIL_PROPERTIES_MAIL_STARTTLS_ENABLE=${MAIL_PROPERTIES_MAIL_STARTTLS_ENABLE}
|
||||
- MAIL_PROPERTIES_MAIL_STARTTLS_REQUIRED=${MAIL_PROPERTIES_MAIL_STARTTLS_REQUIRED}
|
||||
- MAIL_PROPERTIES_MAIL_DEBUG=${MAIL_PROPERTIES_MAIL_DEBUG}
|
||||
- MAIL_SERVER_URL=${MAIL_SERVER_URL}
|
||||
- MAIL_SERVER_PORT=${MAIL_SERVER_PORT}
|
||||
- MAIL_SERVER_USERNAME=${MAIL_SERVER_USERNAME}
|
||||
- MAIL_SERVER_PASSWORD=${MAIL_SERVER_PASSWORD}
|
||||
- MAIL_SENDER_ADDRESS=${MAIL_SENDER_ADDRESS}
|
||||
- MAIL_TRANSPORT_PROTOCOL=${MAIL_TRANSPORT_PROTOCOL}
|
||||
- MAIL_SMTP_PORT=${MAIL_SMTP_PORT}
|
||||
- MAIL_SMTP_AUTH=${MAIL_SMTP_AUTH}
|
||||
- MAIL_SMTP_STARTTLS_ENABLE=${MAIL_SMTP_STARTTLS_ENABLE}
|
||||
- MAIL_SMTP_STARTTLS_REQUIRED=${MAIL_SMTP_STARTTLS_REQUIRED}
|
||||
- MAIL_DEBUG=${MAIL_DEBUG}
|
||||
links:
|
||||
- "pinpoint-mysql:pinpoint-mysql"
|
||||
networks:
|
||||
|
|
|
@ -4,7 +4,6 @@ SPRING_PROFILES=release
|
|||
### Pinpoint-Web
|
||||
|
||||
PINPOINT_WEB_NAME=pinpoint-web
|
||||
SPRING_PROFILES=release
|
||||
|
||||
WEB_PAGE_PORT=8079
|
||||
|
||||
|
@ -23,8 +22,8 @@ HBASE_PORT=
|
|||
WEB_DEBUG_LEVEL=INFO
|
||||
|
||||
#flink server information required if used
|
||||
BATCH_ENABLE=false
|
||||
BATCH_SERVER_IP=127.0.0.127
|
||||
BATCH_ENABLE=true
|
||||
BATCH_SERVER_IP=127.0.0.1
|
||||
BATCH_FLINK_SERVER=pinpoint-flink-jobmanager
|
||||
|
||||
CONFIG_SHOW_APPLICATIONSTAT=true
|
||||
|
@ -32,18 +31,18 @@ CONFIG_SHOW_APPLICATIONSTAT=true
|
|||
#mysql information required
|
||||
JDBC_DRIVER=com.mysql.jdbc.Driver
|
||||
JDBC_URL=jdbc:mysql://pinpoint-mysql:3306/pinpoint?characterEncoding=UTF-8
|
||||
JDBC_USERNAME=
|
||||
JDBC_PASSWORD=
|
||||
JDBC_USERNAME=admin
|
||||
JDBC_PASSWORD=admin
|
||||
|
||||
#mail server information required
|
||||
MAIL_HOST=
|
||||
MAIL_PORT=
|
||||
MAIL_USERNAME=
|
||||
MAIL_PASSWORD=
|
||||
MAIL_PROPERTIES_MAIL_TRANSPORT_PROTOCOL=
|
||||
MAIL_PROPERTIES_MAIL_SMTP_AUTH=
|
||||
MAIL_PROPERTIES_MAIL_SMTP_PORT=
|
||||
MAIL_PROPERTIES_MAIL_SMTP_FROM=
|
||||
MAIL_PROPERTIES_MAIL_STARTTLS_ENABLE=
|
||||
MAIL_PROPERTIES_MAIL_STARTTLS_REQUIRED=
|
||||
MAIL_PROPERTIES_MAIL_DEBUG=
|
||||
MAIL_SERVER_URL=smtp.gmail.com
|
||||
MAIL_SERVER_PORT=587
|
||||
MAIL_SERVER_USERNAME=username
|
||||
MAIL_SERVER_PASSWORD=password
|
||||
MAIL_SENDER_ADDRESS=pinpoint_operator@pinpoint.com
|
||||
MAIL_TRANSPORT_PROTOCOL=smtp
|
||||
MAIL_SMTP_PORT=25
|
||||
MAIL_SMTP_AUTH=false
|
||||
MAIL_SMTP_STARTTLS_ENABLE=false
|
||||
MAIL_SMTP_STARTTLS_REQUIRED=false
|
||||
MAIL_DEBUG=false
|
|
@ -6,16 +6,12 @@ ARG PINPOINT_VERSION=${PINPOINT_VERSION:-2.0.1}
|
|||
ARG INSTALL_URL=https://github.com/naver/pinpoint/releases/download/v${PINPOINT_VERSION}/pinpoint-web-${PINPOINT_VERSION}.war
|
||||
|
||||
COPY /build/scripts/start-web.sh /usr/local/bin/
|
||||
COPY /build/mail.zip /assets/mail.zip
|
||||
|
||||
RUN chmod a+x /usr/local/bin/start-web.sh \
|
||||
&& curl -SL ${INSTALL_URL} -o pinpoint-web.war \
|
||||
&& rm -rf /usr/local/tomcat/webapps \
|
||||
&& mkdir -p /usr/local/tomcat/webapps \
|
||||
&& unzip pinpoint-web.war -d /usr/local/tomcat/webapps/ROOT \
|
||||
&& rm -rf pinpoint-web.war \
|
||||
&& curl -SL https://maven.java.net/content/repositories/releases/com/sun/mail/javax.mail/1.5.2/javax.mail-1.5.2.jar -o /usr/local/tomcat/webapps/ROOT/WEB-INF/lib/javax.mail-1.5.2.jar \
|
||||
&& unzip /assets/mail.zip -d /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/ \
|
||||
&& rm -rf /assets/mail.zip
|
||||
&& rm -rf pinpoint-web.war
|
||||
|
||||
ENTRYPOINT ["/usr/local/bin/start-web.sh"]
|
||||
|
|
Binary file not shown.
|
@ -2,84 +2,43 @@
|
|||
set -e
|
||||
set -x
|
||||
|
||||
sed -i "/cluster.enable=/ s/=.*/=${CLUSTER_ENABLE}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/pinpoint-web.properties
|
||||
sed -i "/cluster.zookeeper.address=/ s/=.*/=${CLUSTER_ZOOKEEPER_ADDRESS}/g" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/pinpoint-web.properties
|
||||
#sed -i "/cluster.web.tcp.port=/ s/=.*/=${CLUSTER_WEB_TCP_PORT}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/pinpoint-web.properties
|
||||
sed -i "/admin.password=/ s/=.*/=${ADMIN_PASSWORD}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/pinpoint-web.properties
|
||||
sed -i "/config.sendUsage=/ s/=.*/=${ANALYTICS}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/pinpoint-web.properties
|
||||
sed -i "/config.show.applicationStat=/ s/=.*/=${CONFIG_SHOW_APPLICATIONSTAT}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/pinpoint-web.properties
|
||||
WEB_INF_CLASSES_DIR=/usr/local/tomcat/webapps/ROOT/WEB-INF/classes
|
||||
APPLICATION_WEB_PROPERTIES=${WEB_INF_CLASSES_DIR}/pinpoint-web.properties
|
||||
APPLICATION_HBASE_PROPERTIES=${WEB_INF_CLASSES_DIR}/profiles/${SPRING_PROFILES}/hbase-env.properties
|
||||
APPLICATION_BATCH_PROPERTIES=${WEB_INF_CLASSES_DIR}/batch.properties
|
||||
APPLICATION_JDBC_PROPERTIES=${WEB_INF_CLASSES_DIR}/jdbc.properties
|
||||
|
||||
sed -i "/hbase.client.host=/ s/=.*/=${HBASE_HOST}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/profiles/${SPRING_PROFILES}/hbase-env.properties
|
||||
sed -i "/hbase.client.port=/ s/=.*/=${HBASE_PORT}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/profiles/${SPRING_PROFILES}/hbase-env.properties
|
||||
sed -i "/cluster.enable=/ s/=.*/=${CLUSTER_ENABLE}/" ${APPLICATION_WEB_PROPERTIES}
|
||||
#sed -i "/cluster.zookeeper.address=/ s/=.*/=${CLUSTER_ZOOKEEPER_ADDRESS}/g" ${APPLICATION_WEB_PROPERTIES}
|
||||
#sed -i "/cluster.web.tcp.port=/ s/=.*/=${CLUSTER_WEB_TCP_PORT}/" ${APPLICATION_WEB_PROPERTIES}
|
||||
sed -i "/admin.password=/ s/=.*/=${ADMIN_PASSWORD}/" ${APPLICATION_WEB_PROPERTIES}
|
||||
sed -i "/config.sendUsage=/ s/=.*/=${ANALYTICS}/" ${APPLICATION_WEB_PROPERTIES}
|
||||
sed -i "/config.show.applicationStat=/ s/=.*/=${CONFIG_SHOW_APPLICATIONSTAT}/" ${APPLICATION_WEB_PROPERTIES}
|
||||
|
||||
sed -i "/batch.enable=/ s/=.*/=${BATCH_ENABLE}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/batch.properties
|
||||
sed -i "/batch.server.ip=/ s/=.*/=${BATCH_SERVER_IP}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/batch.properties
|
||||
sed -i "/batch.flink.server=/ s/=.*/=${BATCH_FLINK_SERVER}/" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/batch.properties
|
||||
sed -i "/hbase.client.host=/ s/=.*/=${HBASE_HOST}/" ${APPLICATION_HBASE_PROPERTIES}
|
||||
sed -i "/hbase.client.port=/ s/=.*/=${HBASE_PORT}/" ${APPLICATION_HBASE_PROPERTIES}
|
||||
|
||||
sed -i "/batch.enable=/ s/=.*/=${BATCH_ENABLE}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/batch.server.ip=/ s/=.*/=${BATCH_SERVER_IP}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/batch.flink.server=/ s/=.*/=${BATCH_FLINK_SERVER}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
|
||||
sed -i "/level value=/ s/=.*/=\"${DEBUG_LEVEL}\"\/>/g" /usr/local/tomcat/webapps/ROOT/WEB-INF/classes/profiles/${SPRING_PROFILES}/log4j.xml
|
||||
sed -i "/jdbc.driverClassName=/ s/=.*/=${JDBC_DRIVER:-com.mysql.jdbc.Driver}/" ${APPLICATION_JDBC_PROPERTIES}
|
||||
sed -i "/jdbc.url=/ s/=.*/=${JDBC_URL//\//\\/}/" ${APPLICATION_JDBC_PROPERTIES}
|
||||
sed -i "/jdbc.username=/ s/=.*/=${JDBC_USERNAME:-admin}/" ${APPLICATION_JDBC_PROPERTIES}
|
||||
sed -i "/jdbc.password=/ s/=.*/=${JDBC_PASSWORD:-admin}/" ${APPLICATION_JDBC_PROPERTIES}
|
||||
|
||||
WEB_INF_CLASSES_DIR=/usr/local/tomcat/webapps/ROOT/WEB-INF/classes
|
||||
APPLICATION_CONTEXT_WEB_FILE=${WEB_INF_CLASSES_DIR}/applicationContext-web.xml
|
||||
APPLICATION_CONTEXT_MAIL_FILE=${WEB_INF_CLASSES_DIR}/applicationContext-mail.xml
|
||||
sed -i "/alarm.mail.server.url=/ s/=.*/=${MAIL_SERVER_URL}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.server.port=/ s/=.*/=${MAIL_SERVER_PORT:-587}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.server.username=/ s/=.*/=${MAIL_SERVER_USERNAME}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.server.password=/ s/=.*/=${MAIL_SERVER_PASSWORD}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.sender.address=/ s/=.*/=${MAIL_SENDER_ADDRESS:-pinpoint_operator@pinpoint.com}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
|
||||
echo -e "
|
||||
jdbc.driverClassName=${JDBC_DRIVER:-com.mysql.jdbc.Driver}
|
||||
jdbc.url=${JDBC_URL:-jdbc:mysql://localhost:13306/pinpoint?characterEncoding=UTF-8}
|
||||
jdbc.username=${JDBC_USERNAME:-admin}
|
||||
jdbc.password=${JDBC_PASSWORD:-admin}
|
||||
" > ${WEB_INF_CLASSES_DIR}/jdbc.properties
|
||||
|
||||
sed -i '/classpath:applicationContext-mail.xml/d' ${APPLICATION_CONTEXT_WEB_FILE}
|
||||
if [ "$MAIL_HOST" != "" ]; then
|
||||
sed -i 's/<\/beans>/ <import resource="classpath:applicationContext-mail.xml" \/>\
|
||||
<\/beans>/' ${APPLICATION_CONTEXT_WEB_FILE}
|
||||
|
||||
sed -i "/name=\"host\"/c\ <property name=\"host\" value=\"${MAIL_HOST}\" />" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
sed -i "/name=\"port\"/c\ <property name=\"port\" value=\"${MAIL_PORT}\" />" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
sed -i "/name=\"username\"/c\ <property name=\"username\" value=\"${MAIL_USERNAME}\" />" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
sed -i "/name=\"password\"/c\ <property name=\"password\" value=\"${MAIL_PASSWORD}\" />" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
|
||||
if [ "$MAIL_PROPERTIES_MAIL_TRANSPORT_PROTOCOL" != "" ]; then
|
||||
sed -i "/prop key=\"mail.transport.protocol\"/c\ <prop key=\"mail.transport.protocol\">${MAIL_PROPERTIES_MAIL_TRANSPORT_PROTOCOL}</prop>" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
else
|
||||
sed -i "/prop key=\"mail.transport.protocol\"/c\ <!-- <prop key=\"mail.transport.protocol\">smtp</prop> -->" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
fi
|
||||
|
||||
if [ "$MAIL_PROPERTIES_MAIL_SMTP_PORT" != "" ]; then
|
||||
sed -i "/prop key=\"mail.smtp.port\"/c\ <prop key=\"mail.smtp.port\">${MAIL_PROPERTIES_MAIL_SMTP_PORT}</prop>" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
else
|
||||
sed -i "/prop key=\"mail.smtp.port\"/c\ <!-- <prop key=\"mail.smtp.port\">25</prop> -->" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
fi
|
||||
|
||||
if [ "$MAIL_PROPERTIES_MAIL_SMTP_AUTH" != "" ]; then
|
||||
sed -i "/prop key=\"mail.smtp.auth\"/c\ <prop key=\"mail.smtp.auth\">${MAIL_PROPERTIES_MAIL_SMTP_AUTH}</prop>" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
else
|
||||
sed -i "/prop key=\"mail.smtp.auth\"/c\ <!-- <prop key=\"mail.smtp.auth\">true</prop> -->" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
fi
|
||||
|
||||
if [ "$MAIL_PROPERTIES_MAIL_STARTTLS_ENABLE" != "" ]; then
|
||||
sed -i "/prop key=\"mail.smtp.starttls.enable\"/c\ <prop key=\"mail.smtp.starttls.enable\">${MAIL_PROPERTIES_MAIL_STARTTLS_ENABLE}</prop>" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
else
|
||||
sed -i "/prop key=\"mail.smtp.starttls.enable\"/c\ <!-- <prop key=\"mail.smtp.starttls.enable\">true</prop> -->" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
fi
|
||||
|
||||
if [ "$MAIL_PROPERTIES_MAIL_STARTTLS_REQUIRED" != "" ]; then
|
||||
sed -i "/prop key=\"mail.smtp.starttls.required\"/c\ <prop key=\"mail.smtp.starttls.required\">${MAIL_PROPERTIES_MAIL_STARTTLS_REQUIRED}</prop>" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
else
|
||||
sed -i "/prop key=\"mail.smtp.starttls.required\"/c\ <!-- <prop key=\"mail.smtp.starttls.required\">true</prop> -->" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
fi
|
||||
|
||||
if [ "$MAIL_PROPERTIES_MAIL_DEBUG" != "" ]; then
|
||||
sed -i "/prop key=\"mail.debug\"/c\ <prop key=\"mail.debug\">${MAIL_PROPERTIES_MAIL_DEBUG}</prop>" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
else
|
||||
sed -i "/prop key=\"mail.debug\"/c\ <!-- <prop key=\"mail.debug\">true</prop> -->" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
fi
|
||||
|
||||
if [ "$MAIL_PROPERTIES_MAIL_SMTP_FROM" != "" ]; then
|
||||
sed -i "/prop key=\"mail.smtp.from\"/c\ <prop key=\"mail.smtp.from\">${MAIL_PROPERTIES_MAIL_SMTP_FROM}</prop>" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
else
|
||||
sed -i "/prop key=\"mail.smtp.from\"/c\ <!-- <prop key=\"mail.smtp.from\">abc@example.com</prop> -->" ${APPLICATION_CONTEXT_MAIL_FILE}
|
||||
fi
|
||||
fi
|
||||
sed -i "/alarm.mail.transport.protocol=/ s/=.*/=${MAIL_TRANSPORT_PROTOCOL:-smtp}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.smtp.port=/ s/=.*/=${MAIL_SMTP_PORT:-587}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.smtp.auth=/ s/=.*/=${MAIL_SMTP_AUTH:-false}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.smtp.starttls.enable=/ s/=.*/=${MAIL_SMTP_STARTTLS_ENABLE:-false}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.smtp.starttls.required=/ s/=.*/=${MAIL_SMTP_STARTTLS_REQUIRED:-false}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
sed -i "/alarm.mail.debug=/ s/=.*/=${MAIL_DEBUG:-false}/" ${APPLICATION_BATCH_PROPERTIES}
|
||||
|
||||
exec /usr/local/tomcat/bin/catalina.sh run
|
||||
|
|
|
@ -19,7 +19,7 @@ services:
|
|||
- "9997:9997"
|
||||
- "${WEB_PAGE_PORT:-8080}:8080"
|
||||
environment:
|
||||
- JAVA_OPTS="-Dspring.profiles.active=${SPRING_PROFILES}"
|
||||
- JAVA_OPTS="-Dspring.profiles.active=${SPRING_PROFILES},batch"
|
||||
- SPRING_PROFILES=${SPRING_PROFILES}
|
||||
- CLUSTER_ENABLE=${CLUSTER_ENABLE}
|
||||
- CLUSTER_ZOOKEEPER_ADDRESS=${CLUSTER_ZOOKEEPER_ADDRESS}
|
||||
|
@ -36,15 +36,14 @@ services:
|
|||
- JDBC_URL=${JDBC_URL}
|
||||
- JDBC_USERNAME=${JDBC_USERNAME}
|
||||
- JDBC_PASSWORD=${JDBC_PASSWORD}
|
||||
- MAIL_HOST=${MAIL_HOST}
|
||||
- MAIL_PORT=${MAIL_PORT}
|
||||
- MAIL_USERNAME=${MAIL_USERNAME}
|
||||
- MAIL_PASSWORD=${MAIL_PASSWORD}
|
||||
- MAIL_PROPERTIES_MAIL_TRANSPORT_PROTOCOL=${MAIL_PROPERTIES_MAIL_TRANSPORT_PROTOCOL}
|
||||
- MAIL_PROPERTIES_MAIL_SMTP_AUTH=${MAIL_PROPERTIES_MAIL_SMTP_AUTH}
|
||||
- MAIL_PROPERTIES_MAIL_SMTP_PORT=${MAIL_PROPERTIES_MAIL_SMTP_PORT}
|
||||
- MAIL_PROPERTIES_MAIL_SMTP_FROM=${MAIL_PROPERTIES_MAIL_SMTP_FROM}
|
||||
- MAIL_PROPERTIES_MAIL_STARTTLS_ENABLE=${MAIL_PROPERTIES_MAIL_STARTTLS_ENABLE}
|
||||
- MAIL_PROPERTIES_MAIL_STARTTLS_REQUIRED=${MAIL_PROPERTIES_MAIL_STARTTLS_REQUIRED}
|
||||
- MAIL_PROPERTIES_MAIL_DEBUG=${MAIL_PROPERTIES_MAIL_DEBUG}
|
||||
|
||||
- MAIL_SERVER_URL=${MAIL_SERVER_URL}
|
||||
- MAIL_SERVER_PORT=${MAIL_SERVER_PORT}
|
||||
- MAIL_SERVER_USERNAME=${MAIL_SERVER_USERNAME}
|
||||
- MAIL_SERVER_PASSWORD=${MAIL_SERVER_PASSWORD}
|
||||
- MAIL_SENDER_ADDRESS=${MAIL_SENDER_ADDRESS}
|
||||
- MAIL_TRANSPORT_PROTOCOL=${MAIL_TRANSPORT_PROTOCOL}
|
||||
- MAIL_SMTP_PORT=${MAIL_SMTP_PORT}
|
||||
- MAIL_SMTP_AUTH=${MAIL_SMTP_AUTH}
|
||||
- MAIL_SMTP_STARTTLS_ENABLE=${MAIL_SMTP_STARTTLS_ENABLE}
|
||||
- MAIL_SMTP_STARTTLS_REQUIRED=${MAIL_SMTP_STARTTLS_REQUIRED}
|
||||
- MAIL_DEBUG=${MAIL_DEBUG}
|
||||
|
|
Loading…
Reference in New Issue