Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building kong-migration luarocks issue (docker-compose up, step 7 of 17) #3

Open
polonia opened this issue Sep 1, 2019 · 1 comment

Comments

@polonia
Copy link

polonia commented Sep 1, 2019

On my fedora 30 machine (5.2.9-200.fc30.x86_64), i have an core dump on the step 7 of 17 of docker-compose up. There is any work arround?

All details are below:

$ docker-compose up
Building kong-migration
Step 1/17 : FROM alpine:3.6
---> 43773d1dba76
Step 2/17 : ENV KONG_VERSION 0.12.1
---> Using cache
---> 60276893fd0b
Step 3/17 : ENV KONG_SHA256 9f699e20e7d3aa6906b14d6b52cae9996995d595d646f9b10ce09c61d91a4257
---> Using cache
---> 2d08100e8359
Step 4/17 : RUN apk update && apk add git && apk add musl-dev && apk add gcc && apk add pcre-dev && apk add --virtual .build-deps wget tar ca-certificates && apk add libgcc openssl pcre perl && wget -O kong.tar.gz "https://bintray.com/kong/kong-community-edition-alpine-tar/download_file?file_path=kong-community-edition-$KONG_VERSION.apk.tar.gz" && echo "$KONG_SHA256 kong.tar.gz" | sha256sum -c - && tar -xzf kong.tar.gz -C /tmp && rm -f kong.tar.gz && cp -R /tmp/usr / && rm -rf /tmp/usr && apk del .build-deps && rm -rf /var/cache/apk/
---> Using cache
---> 75578f19b8df
Step 5/17 : COPY docker-entrypoint.sh /docker-entrypoint.sh
---> Using cache
---> d9eb5e25a7aa
Step 6/17 : ENTRYPOINT ["/docker-entrypoint.sh"]
---> Using cache
---> 41e249d9721c
Step 7/17 : RUN luarocks install busted
---> Running in eeb44d95cdcb
Illegal instruction (core dumped)
ERROR: Service 'kong-migration' failed to build: The command '/bin/sh -c luarocks install busted' returned a non-zero code: 132

@Wolfsrudel
Copy link

FROM alpine

ENV KONG_VERSION 0.12.1
ENV KONG_SHA256 9f699e20e7d3aa6906b14d6b52cae9996995d595d646f9b10ce09c61d91a4257

RUN apk update \
      && apk add git \
      && apk add musl-dev \
      && apk add gcc \
      && apk add pcre-dev \
      && apk add --virtual .build-deps wget tar ca-certificates \
      && apk add libgcc openssl pcre perl \
      && apk add lua5.3 lua5.3-dev luarocks5.3 \
      && wget -O kong.tar.gz "https://download.konghq.com/gateway-0.x-alpine/kong-$KONG_VERSION.apk.tar.gz" \
      && echo "$KONG_SHA256 *kong.tar.gz" | sha256sum -c - \
      && tar -xzf kong.tar.gz -C /tmp \
      && rm -f kong.tar.gz \
      && cp -R /tmp/usr / \
      && rm -rf /tmp/usr \
      && apk del .build-deps \
      && rm -rf /var/cache/apk/*

COPY docker-entrypoint.sh /docker-entrypoint.sh
ENTRYPOINT ["/docker-entrypoint.sh"]

RUN luarocks-5.1 install busted
RUN ln -s /usr/local/openresty/bin/resty /usr/local/bin/resty
RUN mkdir -p /home/kong/bin
RUN mkdir -p /home/kong/spec

COPY busted /home/kong/bin/busted
RUN chmod 755 /home/kong/bin/busted

COPY helpers.lua /home/kong/spec/helpers.lua
COPY kong_tests.conf /home/kong/spec/kong_tests.conf

EXPOSE 8000 8443 8001 8444

STOPSIGNAL SIGTERM

CMD ["/usr/local/openresty/nginx/sbin/nginx", "-c", "/usr/local/kong/nginx.conf", "-p", "/usr/local/kong/"]

Works for me. ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants