This is an automated email from the ASF dual-hosted git repository. rzo1 pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/storm-docker.git
commit d95edc7cb46218e1fcd9a75592cd769b2a4fade1 Author: Richard Zowalla <r...@apache.org> AuthorDate: Tue Jan 16 20:13:59 2024 +0100 Remove EOL versions of Storm from Docker distribution --- 1.2.4/Dockerfile | 72 ----------------------------------- 2.4.0/Dockerfile | 95 ---------------------------------------------- 2.4.0/docker-entrypoint.sh | 22 ----------- 2.5.0/docker-entrypoint.sh | 22 ----------- 4 files changed, 211 deletions(-) diff --git a/1.2.4/Dockerfile b/1.2.4/Dockerfile deleted file mode 100644 index d19c21a..0000000 --- a/1.2.4/Dockerfile +++ /dev/null @@ -1,72 +0,0 @@ -FROM eclipse-temurin:8-jre - -ENV STORM_CONF_DIR=/conf \ - STORM_DATA_DIR=/data \ - STORM_LOG_DIR=/logs - -# Add a user with an explicit UID/GID and create necessary directories -RUN set -eux; \ - groupadd -r storm --gid=1000; \ - useradd -r -g storm --uid=1000 storm; \ - mkdir -p "$STORM_CONF_DIR" "$STORM_DATA_DIR" "$STORM_LOG_DIR"; \ - chown -R storm:storm "$STORM_CONF_DIR" "$STORM_DATA_DIR" "$STORM_LOG_DIR"`` - -# Install required packages -RUN set -eux; \ - apt-get update; \ - DEBIAN_FRONTEND=noninteractive \ - apt-get install -y --no-install-recommends \ - bash \ - ca-certificates \ - dirmngr \ - gosu \ - gnupg \ - python2 \ - procps \ - wget; \ - rm -rf /var/lib/apt/lists/*; \ -# Verify that gosu binary works - gosu nobody true; \ -# Set default version to Python 2 - update-alternatives --install /usr/bin/python python /usr/bin/python2 0 - -ARG GPG_KEY=5167DE337E7370373499FC1DA4A672F11B5050C8 -ARG DISTRO_NAME=apache-storm-1.2.4 - -# Download Apache Storm, verify its PGP signature, untar and clean up -RUN set -eux; \ - ddist() { \ - local f="$1"; shift; \ - local distFile="$1"; shift; \ - local success=; \ - local distUrl=; \ - for distUrl in \ - 'https://www.apache.org/dyn/closer.cgi?action=download&filename=' \ - https://www-us.apache.org/dist/ \ - https://www.apache.org/dist/ \ - https://archive.apache.org/dist/ \ - ; do \ - if wget -q -O "$f" "$distUrl$distFile" && [ -s "$f" ]; then \ - success=1; \ - break; \ - fi; \ - done; \ - [ -n "$success" ]; \ - }; \ - ddist "$DISTRO_NAME.tar.gz" "storm/$DISTRO_NAME/$DISTRO_NAME.tar.gz"; \ - ddist "$DISTRO_NAME.tar.gz.asc" "storm/$DISTRO_NAME/$DISTRO_NAME.tar.gz.asc"; \ - export GNUPGHOME="$(mktemp -d)"; \ - gpg --keyserver hkps://keyserver.pgp.com --recv-key "$GPG_KEY" || \ - gpg --keyserver hkps://keyserver.ubuntu.com --recv-keys "$GPG_KEY" || \ - gpg --keyserver hkps://pgp.mit.edu --recv-keys "$GPG_KEY"; \ - gpg --batch --verify "$DISTRO_NAME.tar.gz.asc" "$DISTRO_NAME.tar.gz"; \ - tar -xzf "$DISTRO_NAME.tar.gz"; \ - rm -rf "$GNUPGHOME" "$DISTRO_NAME.tar.gz" "$DISTRO_NAME.tar.gz.asc"; \ - chown -R storm:storm "$DISTRO_NAME" - -WORKDIR $DISTRO_NAME - -ENV PATH $PATH:/$DISTRO_NAME/bin - -COPY docker-entrypoint.sh / -ENTRYPOINT ["/docker-entrypoint.sh"] diff --git a/2.4.0/Dockerfile b/2.4.0/Dockerfile deleted file mode 100644 index 1675488..0000000 --- a/2.4.0/Dockerfile +++ /dev/null @@ -1,95 +0,0 @@ -FROM eclipse-temurin:11-jre - -ENV STORM_CONF_DIR=/conf \ - STORM_DATA_DIR=/data \ - STORM_LOG_DIR=/logs - -# Add a user with an explicit UID/GID and create necessary directories -RUN set -eux; \ - groupadd -r storm --gid=1000; \ - useradd -r -g storm --uid=1000 storm; \ - mkdir -p "$STORM_CONF_DIR" "$STORM_DATA_DIR" "$STORM_LOG_DIR"; \ - chown -R storm:storm "$STORM_CONF_DIR" "$STORM_DATA_DIR" "$STORM_LOG_DIR"`` - -# Install required packages -RUN set -eux; \ - apt-get update; \ - DEBIAN_FRONTEND=noninteractive \ - apt-get install -y --no-install-recommends \ - bash \ - ca-certificates \ - dirmngr \ - gosu \ - gnupg \ - python2 \ - procps \ - wget; \ - rm -rf /var/lib/apt/lists/*; \ -# Verify that gosu binary works - gosu nobody true; \ -# Set default version to Python 2 - update-alternatives --install /usr/bin/python python /usr/bin/python2 0 - -ARG GPG_KEY=51379DA8A7AE5B02674EF15C134716AF768D9B6E -ARG DISTRO_NAME=apache-storm-2.4.0 - -# Download Apache Storm, verify its PGP signature, untar and clean up -RUN set -eux; \ - ddist() { \ - local f="$1"; shift; \ - local distFile="$1"; shift; \ - local success=; \ - local distUrl=; \ - for distUrl in \ - 'https://www.apache.org/dyn/closer.cgi?action=download&filename=' \ - https://www-us.apache.org/dist/ \ - https://www.apache.org/dist/ \ - https://archive.apache.org/dist/ \ - ; do \ - if wget -q -O "$f" "$distUrl$distFile" && [ -s "$f" ]; then \ - success=1; \ - break; \ - fi; \ - done; \ - [ -n "$success" ]; \ - }; \ - ddist "$DISTRO_NAME.tar.gz" "storm/$DISTRO_NAME/$DISTRO_NAME.tar.gz"; \ - ddist "$DISTRO_NAME.tar.gz.asc" "storm/$DISTRO_NAME/$DISTRO_NAME.tar.gz.asc"; \ - export GNUPGHOME="$(mktemp -d)"; \ - gpg --keyserver hkps://keyserver.pgp.com --recv-key "$GPG_KEY" || \ - gpg --keyserver hkps://keyserver.ubuntu.com --recv-keys "$GPG_KEY" || \ - gpg --keyserver hkps://pgp.mit.edu --recv-keys "$GPG_KEY"; \ - gpg --batch --verify "$DISTRO_NAME.tar.gz.asc" "$DISTRO_NAME.tar.gz"; \ - tar -xzf "$DISTRO_NAME.tar.gz"; \ - rm -rf "$GNUPGHOME" "$DISTRO_NAME.tar.gz" "$DISTRO_NAME.tar.gz.asc"; \ - chown -R storm:storm "$DISTRO_NAME" - -WORKDIR $DISTRO_NAME - -# This is a workaround to make storm workers run in jdk-11 and above. -# Thanks to Raul Negrean (raulnegrean) for the suggestion. -# It should be removed once the fix is included into the storm distribution. -# See more details at https://github.com/apache/storm/pull/3503 and https://github.com/31z4/storm-docker/issues/39 -RUN set -eux; \ - apt-get update; \ - apt-get install -y --no-install-recommends \ - zip \ - unzip; \ - for jar in \ - lib/storm-client-2.4.0.jar \ - lib-worker/storm-client-2.4.0.jar \ - ; do \ - unzip "$jar" defaults.yaml; \ - sed -i 's/worker.childopts: "/&-XX:+IgnoreUnrecognizedVMOptions /' defaults.yaml; \ - zip -u "$jar" defaults.yaml; \ - rm defaults.yaml; \ - done; \ - apt-get purge -y --auto-remove \ - zip \ - unzip; \ - rm -rf /var/lib/apt/lists/* - -ENV PATH $PATH:/$DISTRO_NAME/bin - -COPY docker-entrypoint.sh / -ENTRYPOINT ["/docker-entrypoint.sh"] diff --git a/2.4.0/docker-entrypoint.sh b/2.4.0/docker-entrypoint.sh deleted file mode 100755 index 66dff6f..0000000 --- a/2.4.0/docker-entrypoint.sh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/bash - -set -e - -# Allow the container to be started with `--user` -if [ "$1" = 'storm' -a "$(id -u)" = '0' ]; then - chown -R storm:storm "$STORM_CONF_DIR" "$STORM_DATA_DIR" "$STORM_LOG_DIR" - exec gosu storm "$0" "$@" -fi - -# Generate the config only if it doesn't exist -CONFIG="$STORM_CONF_DIR/storm.yaml" -if [ ! -f "$CONFIG" ]; then - cat << EOF > "$CONFIG" -storm.zookeeper.servers: [zookeeper] -nimbus.seeds: [nimbus] -storm.log.dir: "$STORM_LOG_DIR" -storm.local.dir: "$STORM_DATA_DIR" -EOF -fi - -exec "$@" diff --git a/2.5.0/docker-entrypoint.sh b/2.5.0/docker-entrypoint.sh deleted file mode 100755 index 66dff6f..0000000 --- a/2.5.0/docker-entrypoint.sh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/bash - -set -e - -# Allow the container to be started with `--user` -if [ "$1" = 'storm' -a "$(id -u)" = '0' ]; then - chown -R storm:storm "$STORM_CONF_DIR" "$STORM_DATA_DIR" "$STORM_LOG_DIR" - exec gosu storm "$0" "$@" -fi - -# Generate the config only if it doesn't exist -CONFIG="$STORM_CONF_DIR/storm.yaml" -if [ ! -f "$CONFIG" ]; then - cat << EOF > "$CONFIG" -storm.zookeeper.servers: [zookeeper] -nimbus.seeds: [nimbus] -storm.log.dir: "$STORM_LOG_DIR" -storm.local.dir: "$STORM_DATA_DIR" -EOF -fi - -exec "$@"