diff options
author | leeym <leeym@FreeBSD.org> | 2003-10-26 07:36:31 +0800 |
---|---|---|
committer | leeym <leeym@FreeBSD.org> | 2003-10-26 07:36:31 +0800 |
commit | c9b980e00ce2bf513c6001254bc52a2686c7a275 (patch) | |
tree | 7946b0e772986f7775d50e8db932b15e4b5782af /net-mgmt/zabbix/scripts | |
parent | b8e740cb3d244f984271e763e87dd0a720b744df (diff) | |
download | freebsd-ports-gnome-c9b980e00ce2bf513c6001254bc52a2686c7a275.tar.gz freebsd-ports-gnome-c9b980e00ce2bf513c6001254bc52a2686c7a275.tar.zst freebsd-ports-gnome-c9b980e00ce2bf513c6001254bc52a2686c7a275.zip |
Fixed issues:
* Make use of USE_MYSQL
* Convert scripts to rc.subr
* Fix plist
* Fix pkg-message not displayed during 'make install'
* Depend on net/php4-nms
* Allow to connect to remote MySQL DB
* Even more...
PR: 58061
Submitted by: Sergey Akifyev <asa@gascom.ru>
Diffstat (limited to 'net-mgmt/zabbix/scripts')
-rw-r--r-- | net-mgmt/zabbix/scripts/dbsetup.sh | 7 | ||||
-rw-r--r-- | net-mgmt/zabbix/scripts/zabbix-agent.sh.sample | 24 | ||||
-rw-r--r-- | net-mgmt/zabbix/scripts/zabbix.sh.sample | 26 |
3 files changed, 28 insertions, 29 deletions
diff --git a/net-mgmt/zabbix/scripts/dbsetup.sh b/net-mgmt/zabbix/scripts/dbsetup.sh index 4ae8e4381893..240f46157640 100644 --- a/net-mgmt/zabbix/scripts/dbsetup.sh +++ b/net-mgmt/zabbix/scripts/dbsetup.sh @@ -1,5 +1,6 @@ #!/bin/sh -echo "create database zabbix;" | mysql -cat mysql/schema.sql | mysql zabbix -cat data/data.sql | mysql zabbix +{ + echo "create database zabbix; use zabbix;" + cat mysql/schema.sql data/data.sql +} | mysql ${*} diff --git a/net-mgmt/zabbix/scripts/zabbix-agent.sh.sample b/net-mgmt/zabbix/scripts/zabbix-agent.sh.sample index e5728bd24051..1001c6cb694f 100644 --- a/net-mgmt/zabbix/scripts/zabbix-agent.sh.sample +++ b/net-mgmt/zabbix/scripts/zabbix-agent.sh.sample @@ -1,14 +1,14 @@ #!/bin/sh -case "${1}" in - start) - echo -n "zabbix-agent " - zabbix_agentd - ;; - stop) - killall zabbix_agentd - ;; - *) - echo Usage: `basename ${0}` "{start|stop}" - ;; -esac +prefix=%PREFIX% + +zabbix_agentd_enable="YES" + +. %LOCALBASE%/etc/rc.subr + +name="zabbix_agentd" +rcvar=`set_rcvar` +command="${prefix}/bin/${name}" +required_files="/etc/zabbix/${name}.conf" + +run_rc_command "$1" diff --git a/net-mgmt/zabbix/scripts/zabbix.sh.sample b/net-mgmt/zabbix/scripts/zabbix.sh.sample index 58c0529b4099..01a0fbce27ef 100644 --- a/net-mgmt/zabbix/scripts/zabbix.sh.sample +++ b/net-mgmt/zabbix/scripts/zabbix.sh.sample @@ -1,16 +1,14 @@ #!/bin/sh -case "${1}" in - start) - echo -n "zabbix " - zabbix_suckerd - zabbix_trapperd - ;; - stop) - killall zabbix_suckerd - killall zabbix_trapperd - ;; - *) - echo Usage: `basename ${0}` "{start|stop}" - ;; -esac +prefix=%PREFIX% + +zabbix_suckerd_enable="YES" + +. %LOCALBASE%/etc/rc.subr + +name="zabbix_suckerd" +rcvar=`set_rcvar` +command="${prefix}/bin/${name}" +required_files="/etc/zabbix/${name}.conf" + +run_rc_command "$1" |