From 5fccb78fa17ce9fb52e4b70ea577c9702769d20f Mon Sep 17 00:00:00 2001 From: nic-chen <33000667+nic-chen@users.noreply.github.com> Date: Mon, 8 Jul 2019 12:24:18 +0800 Subject: [PATCH] bugfix: set configuration file to avoid using a wrong one (#220) --- Makefile | 6 +++--- bin/apisix | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 7b6cf63f769e..4f67e54ea039 100644 --- a/Makefile +++ b/Makefile @@ -52,13 +52,13 @@ init: run: mkdir -p logs mkdir -p /tmp/cores/ - $$(which openresty) -p $$PWD/ + $$(which openresty) -p $$PWD/ -c $$PWD/conf/nginx.conf ### stop: Stop the apisix server .PHONY: stop stop: - $$(which openresty) -p $$PWD/ -s stop + $$(which openresty) -p $$PWD/ -c $$PWD/conf/nginx.conf -s stop ### clean: Remove generated files @@ -70,7 +70,7 @@ clean: ### reload: Reload the apisix server .PHONY: reload reload: - $$(which openresty) -p $$PWD/ -s reload + $$(which openresty) -p $$PWD/ -c $$PWD/conf/nginx.conf -s reload ### install: Install the apisix diff --git a/bin/apisix b/bin/apisix index 8e539b02e3b2..c757e5c60cee 100755 --- a/bin/apisix +++ b/bin/apisix @@ -331,8 +331,8 @@ function _M.start(...) init(...) init_etcd(...) - -- print([[openresty -p ]] .. apisix_home) - os.execute([[openresty -p ]] .. apisix_home) + -- print([[openresty -p ]] .. apisix_home .. [[ -c ]] .. apisix_home .. "/conf/nginx.conf") + os.execute([[openresty -p ]] .. apisix_home .. [[ -c ]] .. apisix_home .. "/conf/nginx.conf") end function _M.stop()