Skip to content

Instantly share code, notes, and snippets.

@anon987654321
Last active May 1, 2020 09:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anon987654321/72ab1ad50bf44ec0fac0214ca4fb55c9 to your computer and use it in GitHub Desktop.
Save anon987654321/72ab1ad50bf44ec0fac0214ca4fb55c9 to your computer and use it in GitHub Desktop.
#!/bin/sh
# OpenBSD Puma startup script
# CURRENT STATUS: Failing due to lack of `--bind` switch
# http://cvsweb.openbsd.org/cgi-bin/cvsweb/ports/infrastructure/templates/rc.template
pumactl="/usr/local/bin/pumactl --control-url 'ssl://127.0.0.1:8000?key=/etc/ssl/private/myapp.key&cert=/etc/ssl/myapp.crt' --environment production"
. /etc/rc.d/rc.subr
rc_start() {
${rcexec} "${pumactl} start"
}
rc_check() {
${rcexec} "${pumactl} status"
}
rc_restart() {
${rcexec} "${pumactl} phased-restart"
}
rc_stop() {
${rcexec} "${pumactl} stop"
}
rc_cmd $1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment