Skip to content

Commit

Permalink
fix(lyaml) let luarocks install lyaml (#124)
Browse files Browse the repository at this point in the history
  • Loading branch information
hutchic authored Sep 4, 2019
1 parent 9cf3cc7 commit fb6d21c
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 29 deletions.
3 changes: 0 additions & 3 deletions Dockerfile.openresty
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,9 @@ ARG RESTY_LUAROCKS_VERSION=2.4.3
LABEL resty_luarocks_version="${RESTY_LUAROCKS_VERSION}"

COPY openresty-build-tools /tmp/openresty-build-tools/
COPY install-lyaml.sh /tmp/install-lyaml.sh
COPY build-openresty.sh /tmp/build-openresty.sh

RUN /tmp/build-openresty.sh

RUN /tmp/install-lyaml.sh

RUN sed -i 's/\/tmp\/build//' `grep -l -I -r '\/tmp\/build' /tmp/build/` || true

1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ RESTY_CONFIG_OPTIONS ?= "--with-cc-opt='-I/tmp/openssl/include' \
--with-stream_realip_module \
"
LIBYAML_VERSION ?= 0.2.1
LYAML_VERSION ?= 6.2.3

DOCKER_MACHINE_ARM64_NAME?=docker-machine-arm64-${USER}

Expand Down
10 changes: 4 additions & 6 deletions build-kong.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,6 @@ export GIT_SSH_COMMAND="ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChec
export LUAROCKS_CONFIG=$ROCKS_CONFIG
export LUA_PATH="/usr/local/share/lua/5.1/?.lua;/usr/local/openresty/luajit/share/luajit-2.1.0-beta3/?.lua;;"
export PATH=$PATH:/usr/local/openresty/luajit/bin

/usr/local/bin/luarocks install lyaml 6.2.3 \
YAML_LIBDIR=/tmp/build/usr/local/kong/lib \
YAML_INCDIR=/tmp/yaml-6.2.3 \
CFLAGS="-L/tmp/build/usr/local/kong/lib -Wl,-rpath,/usr/local/kong/lib -O2 -fPIC"

cp -R /tmp/build/* /

Expand Down Expand Up @@ -64,7 +59,10 @@ pushd /kong

/usr/local/bin/luarocks make kong-${ROCKSPEC_VERSION}.rockspec \
CRYPTO_DIR=/usr/local/kong \
OPENSSL_DIR=/usr/local/kong
OPENSSL_DIR=/usr/local/kong \
YAML_LIBDIR=/tmp/build/usr/local/kong/lib \
YAML_INCDIR=/tmp/yaml \
CFLAGS="-L/tmp/build/usr/local/kong/lib -Wl,-rpath,/usr/local/kong/lib -O2 -fPIC"

mkdir -p /tmp/build/etc/kong
cp kong.conf.default /tmp/build/usr/local/lib/luarocks/rock*/kong/$ROCKSPEC_VERSION/
Expand Down
19 changes: 0 additions & 19 deletions install-lyaml.sh

This file was deleted.

0 comments on commit fb6d21c

Please sign in to comment.