Skip to content

Commit

Permalink
luarocks: support to install apisix without dashboard. (#686)
Browse files Browse the repository at this point in the history
* luarocks: support to install apisix without dashboard.
  • Loading branch information
membphis authored Oct 14, 2019
1 parent 13f9b11 commit d4ff56e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .travis/linux_runner.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export_or_prefix() {
}

create_lua_deps() {
sudo luarocks make --lua-dir=${OPENRESTY_PREFIX}/luajit rockspec/apisix-dev-1.0-0.rockspec --tree=deps --only-deps --local
WITHOUT_DASHBOARD=1 sudo luarocks make --lua-dir=${OPENRESTY_PREFIX}/luajit rockspec/apisix-dev-1.0-0.rockspec --tree=deps --only-deps --local
sudo luarocks install --lua-dir=${OPENRESTY_PREFIX}/luajit lua-resty-libr3 --tree=deps --local
echo "Create lua deps cache"
sudo rm -rf build-cache/deps
Expand Down
4 changes: 3 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ dev:
ifeq ($(UNAME),Darwin)
luarocks install --lua-dir=$(LUA_JIT_DIR) rockspec/apisix-dev-1.0-0.rockspec --tree=deps --only-deps --local
else ifneq ($(LUAROCKS_VER),'luarocks 3.')
luarocks install rockspec/apisix-dev-1.0-0.rockspec --tree=deps --only-deps --local
WITHOUT_DASHBOARD=1 luarocks install rockspec/apisix-dev-1.0-0.rockspec --tree=deps --only-deps --local
else
luarocks install --lua-dir=/usr/local/openresty/luajit rockspec/apisix-dev-1.0-0.rockspec --tree=deps --only-deps --local
endif
Expand Down Expand Up @@ -99,13 +99,15 @@ reload:
### install: Install the apisix
.PHONY: install
install:
ifneq ($(WITHOUT_DASHBOARD),1)
$(INSTALL) -d /usr/local/apisix/dashboard
cd `mktemp -d /tmp/apisix.XXXXXX` && \
git clone https://github.com/iresty/apisix.git && \
cd apisix && \
git submodule update --init --recursive && \
cp -r dashboard/* /usr/local/apisix/dashboard
chmod -R 755 /usr/local/apisix/dashboard
endif

$(INSTALL) -d /usr/local/apisix/logs/
$(INSTALL) -d /usr/local/apisix/conf/cert
Expand Down

0 comments on commit d4ff56e

Please sign in to comment.