diff options
author | wen <wen@FreeBSD.org> | 2010-03-08 14:26:53 +0800 |
---|---|---|
committer | wen <wen@FreeBSD.org> | 2010-03-08 14:26:53 +0800 |
commit | ed407a7dffbb4d5299bd546c33632bd6f1295c5f (patch) | |
tree | 60e4dbcc81e90f788592db8e29fb48cc9ece7690 /finance/openerp-server | |
parent | 55fa79d18363ff1f7e71aec6e27adebdb37f1815 (diff) | |
download | freebsd-ports-gnome-ed407a7dffbb4d5299bd546c33632bd6f1295c5f.tar.gz freebsd-ports-gnome-ed407a7dffbb4d5299bd546c33632bd6f1295c5f.tar.zst freebsd-ports-gnome-ed407a7dffbb4d5299bd546c33632bd6f1295c5f.zip |
- Add rc scripts, pkg-message etc.
Thanks to: dougb@, borja@pexego.es, jim@reptiles.org, jean-yves.boisiaud@osiell.com
Feature safe: yes
Diffstat (limited to 'finance/openerp-server')
-rw-r--r-- | finance/openerp-server/Makefile | 11 | ||||
-rw-r--r-- | finance/openerp-server/files/openerp-server.conf.in | 55 | ||||
-rw-r--r-- | finance/openerp-server/files/openerpd.in | 32 | ||||
-rw-r--r-- | finance/openerp-server/files/pkg-message.in | 10 |
4 files changed, 107 insertions, 1 deletions
diff --git a/finance/openerp-server/Makefile b/finance/openerp-server/Makefile index 5f277e6f5de7..163da9ad91a3 100644 --- a/finance/openerp-server/Makefile +++ b/finance/openerp-server/Makefile @@ -7,7 +7,7 @@ PORTNAME= openerp-server PORTVERSION= 5.0.6 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= finance python MASTER_SITES= http://openerp.com/download/stable/source/ @@ -27,6 +27,10 @@ BUILD_DEPENDS= ${PYTHON_SITELIBDIR}/PIL/__init__.py:${PORTSDIR}/graphics/py-imag ${PYTHON_SITELIBDIR}/reportlab/__init__.py:${PORTSDIR}/print/py-reportlab2 RUN_DEPENDS= ${BUILD_DEPENDS} +USE_RC_SUBR= openerpd +SUB_FILES= openerp-server.conf pkg-message +SUB_LIST= PYTHON_SITELIBDIR=${PYTHON_SITELIBDIR} + USE_PYTHON= 2.4+ USE_PYDISTUTILS= yes PYDISTUTILS_EGGINFO= openerp_server-5.0.6-${PYTHON_VERSION:S/thon//}.egg-info @@ -47,10 +51,15 @@ post-install: ${INSTALL_MAN} ${WRKSRC}/man/openerp-server.1 ${PREFIX}/man/man1 ${INSTALL_MAN} ${WRKSRC}/man/openerp_serverrc.5 ${PREFIX}/man/man5 + ${INSTALL_DATA} ${WRKDIR}/openerp-server.conf ${PREFIX}/etc/openerp-server.conf + @${ECHO} etc/openerp-server.conf >> ${TMPPLIST} + @${ECHO} bin/openerp-server >> ${TMPPLIST} @${FIND} -s -d ${PYTHON_SITELIBDIR}/${PORTNAME} \ -type f | ${SED} 's#${PREFIX}/##g' >> ${TMPPLIST} @${FIND} -s -d ${PYTHON_SITELIBDIR}/${PORTNAME} \ -type d | ${SED} 's#${PREFIX}/#@dirrm #g' >> ${TMPPLIST} + @${CAT} ${PKGMESSAGE} + .include <bsd.port.post.mk> diff --git a/finance/openerp-server/files/openerp-server.conf.in b/finance/openerp-server/files/openerp-server.conf.in new file mode 100644 index 000000000000..f374b6796164 --- /dev/null +++ b/finance/openerp-server/files/openerp-server.conf.in @@ -0,0 +1,55 @@ +# Example configuration file for OpenERP-server +# +# This is an example configuration file, just copy it +# to openerp-server.conf and edit it to suit your needs. + +[options] +# Basic daemon configuration options ################## +root_path = %%PYTHON_SITELIBDIR%%/openerp-server/ +addons_path = %%PYTHON_SITELIBDIR%%/openerp-server/addons +# netinterface = +# interface = +port = 8069 +netport = 8070 +debug_mode = False +stop_after_init = False +soap = False +xmlrpc = True +netrpc = True +secure = False +cache_timeout = 100000 +pidfile = /var/run/openerp-server/openerp-server.pid +reportgz = False +admin_passwd = admin +login_message = False +price_accuracy = 2 +csv_internal_sep = , +translate_modules = ['all'] + +# Logging options ##################################### +syslog = False +log_level = info +logfile = /var/log/openerp-server.log +assert_exit_level = warn + +# Database options #################################### +db_name = openerp-server +db_user = openerp-server +db_password = openerp-server +db_host = localhost +db_maxconn = 64 +pg_path = /usr/local/bin +list_db = True +# import_partial = + +# SMTP options ######################################## +smtp_server = localhost +smtp_port = 25 +smtp_user = False +smtp_password = False +email_from = False + +# Use demo files? ##################################### +# without_demo = True +# demo = {} + diff --git a/finance/openerp-server/files/openerpd.in b/finance/openerp-server/files/openerpd.in new file mode 100644 index 000000000000..4adc8a0fae8e --- /dev/null +++ b/finance/openerp-server/files/openerpd.in @@ -0,0 +1,32 @@ +#!/bin/sh + +# PROVIDE: openerpd +# REQUIRE: postgresql LOGIN +# +# Add the following lines to /etc/rc.conf +# to enable this service: +# +# openerpd_enable (bool): Set to NO by default. +# Set it to YES to enable mongod. +# +# Additional configurable variables: +# openerpd_config (path): Set to %%PREFIX%%/etc/openerp-server.conf +# by default. Additional configuration. You +# can also use openerpd_flags for additional +# command line arguments. + +. %%RC_SUBR%% + +name="openerpd" +rcvar=${name}_enable + +command=%%PREFIX%%/bin/openerp-server + +load_rc_config $name + +: ${openerpd_enable="NO"} +: ${openerpd_config="%%PREFIX%%/etc/openerp-server.conf"} + +command_args="-c /usr/local/bin/openerp-server.conf >/dev/null 2>&1 &" + +run_rc_command "$1" diff --git a/finance/openerp-server/files/pkg-message.in b/finance/openerp-server/files/pkg-message.in new file mode 100644 index 000000000000..4827f7412af6 --- /dev/null +++ b/finance/openerp-server/files/pkg-message.in @@ -0,0 +1,10 @@ +************************************************************************ + + +Now you can run the program with %%PREFIX%%/bin/openerp-server, + +If you want start it when the system boot, please add this line +to your /etc/rc.conf: + openerpd_enable="YES" + +************************************************************************ |