diff --git a/docker/dockbuild.sh b/docker/dockbuild.sh index 0793f22..9249d34 100755 --- a/docker/dockbuild.sh +++ b/docker/dockbuild.sh @@ -18,7 +18,7 @@ PACKAGE_NAME=oar-metadata ## containers to be built. List them in dependency order (where a latter one ## depends the former ones). # -DOCKER_IMAGE_DIRS="pymongo jqfromsrc ejsonschema mdtests" +DOCKER_IMAGE_DIRS="pymongo jq ejsonschema mdtests" . $codedir/oar-build/_dockbuild.sh diff --git a/docker/ejsonschema/Dockerfile b/docker/ejsonschema/Dockerfile index 1af09a7..95f3e11 100644 --- a/docker/ejsonschema/Dockerfile +++ b/docker/ejsonschema/Dockerfile @@ -1,4 +1,4 @@ -FROM oar-metadata/jqfromsrc:latest +FROM oar-metadata/jq RUN apt-get update && apt-get install -y unzip uwsgi uwsgi-src \ uuid-dev libcap-dev libpcre3-dev python3-distutils diff --git a/docker/jq/Dockerfile b/docker/jq/Dockerfile index a4dca55..686eb4d 100644 --- a/docker/jq/Dockerfile +++ b/docker/jq/Dockerfile @@ -6,13 +6,17 @@ RUN apt-get update && \ WORKDIR /root # Download a jq binary and do a checksum check on it -COPY jq.sha256 . -RUN curl -L -o jq-linux64 \ - https://github.com/stedolan/jq/releases/download/jq-1.5/jq-linux64 && \ - sha256sum -c jq.sha256 +COPY jq-linux-amd64.sha256 jq-linux-arm64.sha256 ./ +RUN arch=$(uname -m) && \ + { [ "$arch" != "x86_64" ] || arch="amd64"; } && \ + curl -L -o jq-linux-$arch \ + https://github.com/stedolan/jq/releases/download/jq-1.7.1/jq-linux-$arch && \ + sha256sum -c jq-linux-$arch.sha256 # install jq -RUN chmod a+x jq-linux64 && cp jq-linux64 /usr/local/bin/jq +RUN arch=$(uname -m) && \ + { [ "$arch" != "x86_64" ] || arch="amd64"; } && \ + chmod a+x jq-linux-$arch && cp jq-linux-$arch /usr/local/bin/jq CMD ["bash"] diff --git a/docker/jq/jq-linux-amd64.sha256 b/docker/jq/jq-linux-amd64.sha256 new file mode 100644 index 0000000..2aea522 --- /dev/null +++ b/docker/jq/jq-linux-amd64.sha256 @@ -0,0 +1 @@ +5942c9b0934e510ee61eb3e30273f1b3fe2590df93933a93d7c58b81d19c8ff5 jq-linux-amd64 diff --git a/docker/jq/jq-linux-arm64.sha256 b/docker/jq/jq-linux-arm64.sha256 new file mode 100644 index 0000000..87ff389 --- /dev/null +++ b/docker/jq/jq-linux-arm64.sha256 @@ -0,0 +1 @@ +4dd2d8a0661df0b22f1bb9a1f9830f06b6f3b8f7d91211a1ef5d7c4f06a8b4a5 jq-linux-arm64 diff --git a/docker/jq/jq.sha256 b/docker/jq/jq.sha256 deleted file mode 100644 index db021fb..0000000 --- a/docker/jq/jq.sha256 +++ /dev/null @@ -1 +0,0 @@ -c6b3a7d7d3e7b70c6f51b706a3b90bd01833846c54d32ca32f0027f00226ff6d jq-linux64 diff --git a/docker/jqfromsrc/Dockerfile b/docker/jqfromsrc/Dockerfile index 258e41d..b96eda8 100644 --- a/docker/jqfromsrc/Dockerfile +++ b/docker/jqfromsrc/Dockerfile @@ -11,7 +11,6 @@ RUN git clone http://github.com/stedolan/jq.git jq-dev && \ git checkout a9f97e9e61a910a374a5d768244e8ad63f407d3e && \ git submodule update --init && \ autoreconf -fi && \ - (cd docs && pipenv install) && \ ./configure --with-oniguruma=builtin && \ make -j8 && \ make check-TESTS && \ diff --git a/docker/pymongo/Dockerfile b/docker/pymongo/Dockerfile index 4809aab..36f3645 100644 --- a/docker/pymongo/Dockerfile +++ b/docker/pymongo/Dockerfile @@ -22,3 +22,4 @@ ENV LANGUAGE en_US:en ENV LC_ALL en_US.UTF-8 RUN python -m pip install pymongo +ENV HOME /root