-
Notifications
You must be signed in to change notification settings - Fork 530
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
Add s390x support to docker images #208
Comments
I have the Travis CI aspect of it done -- it was straight forward as I made the tooling generic, so it was easy. Can you paste a diff you needed for one of the Dockerfiles so I can follow it? I don't have anything to build on to test locally. But I will push to a test CI/CD branch. |
Thanks @neomantra ! Sure, below is the diff log for the Ubuntu focal Dockerfile: diff --git a/focal/Dockerfile b/focal/Dockerfile
index b5d0879..975e90f 100644
--- a/focal/Dockerfile
+++ b/focal/Dockerfile
@@ -94,6 +94,7 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update \
libperl-dev \
libreadline-dev \
libxslt1-dev \
+ libpcre3-dev \
make \
perl \
unzip \
@@ -124,19 +125,6 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update \
&& make -j${RESTY_J} \
&& make -j${RESTY_J} install_sw \
&& cd /tmp \
- && curl -fSL https://downloads.sourceforge.net/project/pcre/pcre/${RESTY_PCRE_VERSION}/pcre-${RESTY_PCRE_VERSION}.tar.gz -o pcre-${RESTY_PCRE_VERSION}.tar.gz \
- && echo "${RESTY_PCRE_SHA256} pcre-${RESTY_PCRE_VERSION}.tar.gz" | shasum -a 256 --check \
- && tar xzf pcre-${RESTY_PCRE_VERSION}.tar.gz \
- && cd /tmp/pcre-${RESTY_PCRE_VERSION} \
- && ./configure \
- --prefix=/usr/local/openresty/pcre \
- --disable-cpp \
- --enable-jit \
- --enable-utf \
- --enable-unicode-properties \
- && make -j${RESTY_J} \
- && make -j${RESTY_J} install \
- && cd /tmp \
&& curl -fSL https://openresty.org/download/openresty-${RESTY_VERSION}.tar.gz -o openresty-${RESTY_VERSION}.tar.gz \
&& tar xzf openresty-${RESTY_VERSION}.tar.gz \
&& cd /tmp/openresty-${RESTY_VERSION} \
@@ -146,7 +134,6 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update \
&& cd /tmp \
&& rm -rf \
openssl-${RESTY_OPENSSL_VERSION}.tar.gz openssl-${RESTY_OPENSSL_VERSION} \
- pcre-${RESTY_PCRE_VERSION}.tar.gz pcre-${RESTY_PCRE_VERSION} \
openresty-${RESTY_VERSION}.tar.gz openresty-${RESTY_VERSION} \
&& curl -fSL https://luarocks.github.io/luarocks/releases/luarocks-${RESTY_LUAROCKS_VERSION}.tar.gz -o luarocks-${RESTY_LUAROCKS_VERSION}.tar.gz \
&& tar xzf luarocks-${RESTY_LUAROCKS_VERSION}.tar.gz \ |
@neomantra I've tested the built s390x image locally. Please feel free to let me know if you also need s390x VMs for building and testing. Thank you! |
I just got an IBM Cloud s390x VM on the free tier -- I should be fine for a bit. I see that PCRE is not building because its JIT is not supported on It seems there is discussion about this: All of this affect the upstream ticket too. So I will not take your approach of using the system PCRE, but rather modify the Dockerfiles to accept JIT-less PCRE build and note it in the README. |
@neomantra Yes, JIT in PCRE is not supported on s390x yet. Thanks for the detailed info! Sure, disabling the |
Flavors: alpine, alpine-fat, bionic, focal/jammy Build-from-source Dockfiles now have more custom PCRE build options as s390x does not support PCRE JIT. So we disable it in s390x builds.
Seems that there's some issue with Alpine builds. It works if you build the image on bare metal or a VM, but it is not working on Travis Docker-in-Docker environment. I've had image build issues like this before regarding Alpine and they are not very tractable. So I'm going to omit Alpine for now. |
@neomantra I see. Thank you very much! |
This is released on built-from-source Ubuntu flavors:
Have fun! |
Great! Thanks again @neomantra |
Hi,
Since OpenResty could be built from source on s390x with similar steps to amd64 arch now, and Travis CI has s390x support as well, we would greatly appreciate it if community can provide official s390x docker images.
The existing Dockerfiles need to be adjusted slightly to exclude PCRE build steps which do not support s390x yet. If community agrees to add s390x to "build-from-source" flavors, I can raise a PR to add Dockerfiles for s390x.
Thanks!
The text was updated successfully, but these errors were encountered: