mail/openemm2013: cleanup
- fix .py files - logdir added - pkg-message enhanced with variables for some pathes PR: 196516 Submitted by: Horst Leitenmueller <horst.leitenmueller@liwest.at> (maintainer)
This commit is contained in:
parent
7263e9181b
commit
1fdcffa8de
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=400134
3 changed files with 57 additions and 16 deletions
|
@ -3,6 +3,7 @@
|
|||
|
||||
PORTNAME= openemm2013
|
||||
PORTVERSION= R2
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= mail java www
|
||||
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:S/$/:DEFAULT/} \
|
||||
http://central.maven.org/maven2/%SUBDIR%/:MAVEN2
|
||||
|
@ -48,12 +49,14 @@ PID_FILE= ${VAR_DIR}/run/${PORTNAME}.pid
|
|||
|
||||
AGN_BACKEND_FILES= lib tools xmlback bav
|
||||
|
||||
SUB_FILES= pkg-message
|
||||
SUB_LIST= APP_SHORTNAME=${PORTNAME} \
|
||||
LOG_DIR=${LOG_DIR} \
|
||||
USER=${USER} \
|
||||
GROUP=${GROUP} \
|
||||
PID_FILE=${PID_FILE} \
|
||||
APP_HOME=${PREFIX}/${PORTNAME}
|
||||
APP_HOME=${PREFIX}/${PORTNAME} \
|
||||
PREFIX=${PREFIX}
|
||||
PLIST_SUB= APP_HOME=${PORTNAME}
|
||||
|
||||
TOMCAT_CONFIG_FILES= context.xml logging.properties server.xml
|
||||
|
@ -94,9 +97,33 @@ post-patch:
|
|||
${REINPLACE_CMD} -e 's|\/home\/openemm|${PREFIX}\/${PORTNAME}|g' ${WRKSRC}/src/script/data/bav.rc
|
||||
${REINPLACE_CMD} -e 's|\/home\/openemm|${PREFIX}\/${PORTNAME}|g' ${WRKSRC}/tomcat/conf/server.xml
|
||||
|
||||
${REINPLACE_CMD} -e "s|base = os.environ\['HOME'\]| base = '${PREFIX}\/${PORTNAME}'|g" -e "s|lockpath = os.environ\['LOCK_HOME'\]|lockpath = '/var/run/openemm'|g" ${WRKSRC}/src/script/lib/agn.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' -e "s|base = os.environ\['HOME'\]| base = '${PREFIX}\/${PORTNAME}'|g" -e "s|lockpath = os.environ\['LOCK_HOME'\]|lockpath = '/var/run/openemm'|g" ${WRKSRC}/src/script/lib/agn.py
|
||||
|
||||
${REINPLACE_CMD} -e 's|$$HOME|\${PREFIX}\/\${PORTNAME}|g' ${WRKSRC}/src/script/lib/config.sh
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/slrtscn.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/semu.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/softbounce.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/pickdist.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/smenable.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/bavd.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/bav-update.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/bav-trigger.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/upgrade.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/update.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/script/process/recovery.py
|
||||
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|g' ${WRKSRC}/src/script/lib/aps.readme
|
||||
|
||||
${REINPLACE_CMD} -e 's|$$HOME|\${PREFIX}\/\${PORTNAME}|g' -e 's|python -c|${PYTHON_CMD} -c|g' ${WRKSRC}/src/script/lib/config.sh
|
||||
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/fckcommands.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/zope.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/fckoutput.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/connector.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/upload.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/fckutil.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/fckconnector.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/config.py
|
||||
${REINPLACE_CMD} -e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' ${WRKSRC}/src/jsp/fckeditor-2.6.6/editor/filemanager/connectors/py/wsgi.py
|
||||
|
||||
${REINPLACE_CMD} -e 's|$$HOME|\${PREFIX}\/\${PORTNAME}|g' -e 's|-L INFO|-L INFO -s /var/run/openemm/bav.sock|' ${WRKSRC}/src/script/control/bounce.sh
|
||||
${REINPLACE_CMD} -e 's|$$HOME|\${PREFIX}\/\${PORTNAME}|g' ${WRKSRC}/src/script/control/bav-update.sh
|
||||
|
@ -213,4 +240,12 @@ post-install:
|
|||
${MKDIR} ${STAGEDIR}${DOCSDIR}
|
||||
(cd ${WRKSRC}/USR_SHARE/ && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
|
||||
|
||||
# create log files
|
||||
${MKDIR} ${STAGEDIR}/var/log/${PORTNAME}
|
||||
${TOUCH} ${STAGEDIR}/var/log/${PORTNAME}/openemm_core.log
|
||||
${TOUCH} ${STAGEDIR}/var/log/${PORTNAME}/userlogs.log
|
||||
${TOUCH} ${STAGEDIR}/var/log/${PORTNAME}/openemm_axis.log
|
||||
${TOUCH} ${STAGEDIR}/var/log/${PORTNAME}/daily.log
|
||||
${CHOWN} -R ${USER}:${GROUP} ${STAGEDIR}/var/log/${PORTNAME}
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
To integrate the OpenEMM 2013 R2 to the installed Tomcat add this
|
||||
chunk to the server.xml of Tomcat:
|
||||
TOMCAT_HOME= ${PREFIX}/apache-tomcat-8.0/lib/
|
||||
TOMCAT_HOME= %%PREFIX%%/apache-tomcat-8.0/lib/
|
||||
|
||||
vi TOMCAT_HOME/conf/server.xml
|
||||
|
||||
|
@ -13,16 +13,16 @@ vi TOMCAT_HOME/conf/server.xml
|
|||
resolveHosts="false" directory="${catalina.base}/logs/access/" rotatable="true" buffered="true"
|
||||
prefix="" suffix="-access_openemm.log" fileDateFormat="yyyyMMdd"
|
||||
pattern='%a %l %u %t "%r" %s %b "%{Referer}i" "%{User-Agent}i"' />
|
||||
<Context cookies="false" docBase="${PREFIX}/${PORTNAME}/webapps/openemm" path="/openemm" reloadable="true" >
|
||||
<Context cookies="false" docBase="%%APP_HOME%%/webapps/openemm" path="/openemm" reloadable="true" >
|
||||
<JarScanner scanAllDirectories="true" scanBootstrapClassPath="true"/>
|
||||
</Context>
|
||||
<Context cookies="false" docBase="${PREFIX}/${PORTNAME}/webapps/openemm-ws" path="/openemm-ws2" reloadable="true" />
|
||||
<Context docBase="${PREFIX}/${PORTNAME}/webapps/manual" path="/manual" allowLinking="true" />
|
||||
<Context cookies="false" docBase="%%APP_HOME%%/webapps/openemm-ws" path="/openemm-ws2" reloadable="true" />
|
||||
<Context docBase="%%APP_HOME%%/webapps/manual" path="/manual" allowLinking="true" />
|
||||
</Host>
|
||||
<!-- add this part END -->
|
||||
</Engine>
|
||||
|
||||
Also don't forget securing tomcat, or add a httpd in front secured
|
||||
Don't forget securing tomcat, or add a httpd in front secured
|
||||
|
||||
# IMPORTANT sendmail is completly controlled from OpenEMM!
|
||||
# It stops and starts sendmail
|
||||
|
@ -30,7 +30,7 @@ Also don't forget securing tomcat, or add a httpd in front secured
|
|||
sendmail_enable="YES"
|
||||
|
||||
# check also if you have a symlink to sendmail
|
||||
ln -s /etc/rc.d/sendmail /etc/init.d/
|
||||
ln -s /etc/rc.d/sendmail /etc/rc.d/
|
||||
|
||||
# update the read right on the maillog file
|
||||
chmod 644 /var/log/maillog
|
||||
|
@ -41,7 +41,7 @@ chmod 644 /var/log/maillog
|
|||
if not change tracking of mail sending / bounces is not working correct
|
||||
|
||||
# don't forget to add the link for mysql driver jar to tomcat
|
||||
ln -s ${PREFIX}/share/java/classes/mysql-connector-java.jar TOMCAT_HOME/lib
|
||||
ln -s %%PREFIX%%/share/java/classes/mysql-connector-java.jar TOMCAT_HOME/lib
|
||||
chown -h www TOMCAT_HOME/lib/mysql-connector-java.jar
|
||||
|
||||
# setup the database scripts
|
||||
|
@ -58,14 +58,13 @@ grant all privileges on openemm_cms.* to agnitas@'X.Y.%' identified by 'openemm'
|
|||
flush privileges;
|
||||
|
||||
# import the inital data
|
||||
mysql -u root -p openemm < ${PREFIX}/share/doc/openemm2013/openemm-2013.sql
|
||||
usr/local/share/doc/openemm2013/
|
||||
mysql -u root -p openemm_cms < ${PREFIX}/share/doc/openemm2013/openemm-2013.sql
|
||||
mysql -u root -p openemm < %%PREFIX%%/share/doc/openemm2013/openemm-2013.sql
|
||||
mysql -u root -p openemm_cms < %%PREFIX%%/share/doc/openemm2013/openemm_cms-2013.sql
|
||||
|
||||
#additional config for db acces can be done
|
||||
${PREFIX}/openemm2013/webapps/openemm/WEB-INF/classes/emm.properties
|
||||
%%PREFIX%%/openemm2013/webapps/openemm/WEB-INF/classes/emm.properties
|
||||
or
|
||||
${PREFIX}/openemm2013/webapps/openemm/WEB-INF/classes/cms.properties
|
||||
%%PREFIX%%/openemm2013/webapps/openemm/WEB-INF/classes/cms.properties
|
||||
|
||||
# startup config for tomcat and OpenEMM
|
||||
add to /etc/rc.conf
|
||||
|
@ -80,4 +79,6 @@ openemm2013_enable="YES"
|
|||
|
||||
service tomcat8 start
|
||||
|
||||
${PREFIX}/etc/rc.d/openemm2013 start
|
||||
service openemm2013 start
|
||||
or
|
||||
%%PREFIX%%/etc/rc.d/openemm2013 start
|
|
@ -4917,6 +4917,11 @@
|
|||
%%APP_HOME%%/webservices/EmmSoapClient.sh
|
||||
%%APP_HOME%%/webservices/WSSESoapClient.php
|
||||
%%APP_HOME%%/webservices/WS_use_example.php
|
||||
/var/log/%%APP_HOME%%/daily.log
|
||||
/var/log/%%APP_HOME%%/openemm_axis.log
|
||||
/var/log/%%APP_HOME%%/openemm_core.log
|
||||
/var/log/%%APP_HOME%%/userlogs.log
|
||||
@dir /var/log/%%APP_HOME%%
|
||||
@dir %%DOCSDIR%%/ThirdPartyLicences
|
||||
@dir %%DOCSDIR%%
|
||||
@dir %%APP_HOME%%/bin/scripts
|
||||
|
|
Loading…
Reference in a new issue