chef/cookbooks/mysql/templates/default/smf/svc.method.mysqld.erb
Greg Karékinian a32f34b408 Vendor the external cookbooks
Knife-Zero doesn't include Berkshelf support, so vendoring everything in
the repo is convenient again
2019-10-13 19:17:42 +02:00

29 lines
555 B
Plaintext

#!/sbin/sh
#
# Generated by Chef
#
. /lib/svc/share/smf_include.sh
ulimit -n 10240
case "$1" in
start)
<%= @mysqld_bin %> \
--defaults-file=<%= @defaults_file %> \
--basedir=<%= @base_dir %> \
--datadir=<%= @data_dir %> \
--pid-file=<%= @pid_file %> \
--log-error=<%= @error_log %> &
;;
stop)
[ -f <%= @pid_file %> ] && kill `/usr/bin/head -1 <%= @pid_file %>`
;;
*)
echo "Usage: $0 {start|stop}" >&2
exit 1
;;
esac
exit $SMF_EXIT_OK