hapi-fhir/vagrant/chef/cookbooks/mysql/templates/default/omnios/svc.method.mysqld.erb

30 lines
556 B
Plaintext
Raw Normal View History

2014-10-06 21:47:56 -04:00
#!/sbin/sh
#
# Generated by Chef
#
. /lib/svc/share/smf_include.sh
PIDFILE=<%= @pid_file %>
ulimit -n 10240
case "$1" in
start)
<%= @base_dir %>/bin/mysqld --user=mysql \
--basedir=<%= @base_dir %> \
--datadir=<%= @data_dir %> \
--pid-file=${PIDFILE} \
--log-error=/var/log/mysql/error.log &
;;
stop)
[ -f ${PIDFILE} ] && kill `/usr/bin/head -1 ${PIDFILE}`
;;
*)
echo "Usage: $0 {start|stop}" >&2
exit 1
;;
esac
exit $SMF_EXIT_OK