82 lines
5.4 KiB
Docker
82 lines
5.4 KiB
Docker
FROM docker.io/bitnami/minideb:bullseye
|
|
|
|
ARG JAVA_EXTRA_SECURITY_DIR="/bitnami/java/extra-security"
|
|
ARG TARGETARCH
|
|
|
|
LABEL org.opencontainers.image.authors="https://bitnami.com/contact" \
|
|
org.opencontainers.image.description="Application packaged by Bitnami" \
|
|
org.opencontainers.image.ref.name="4.0.6-debian-11-r5" \
|
|
org.opencontainers.image.source="https://github.com/bitnami/containers/tree/main/bitnami/cassandra" \
|
|
org.opencontainers.image.title="cassandra" \
|
|
org.opencontainers.image.vendor="VMware, Inc." \
|
|
org.opencontainers.image.version="4.0.6"
|
|
|
|
ENV HOME="/" \
|
|
OS_ARCH="${TARGETARCH:-amd64}" \
|
|
OS_FLAVOUR="debian-11" \
|
|
OS_NAME="linux"
|
|
|
|
COPY prebuildfs /
|
|
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
|
|
# Install required system packages and dependencies
|
|
RUN install_packages acl ca-certificates curl gzip libbz2-1.0 libc6 libcom-err2 libcrypt1 libffi7 libgcc-s1 libgssapi-krb5-2 libjemalloc2 libk5crypto3 libkeyutils1 libkrb5-3 libkrb5support0 liblzma5 libncursesw6 libnsl2 libreadline8 libsqlite3-0 libssl1.1 libtinfo6 libtirpc3 procps tar zlib1g
|
|
RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
|
if [ ! -f python-3.9.14-1-linux-${OS_ARCH}-debian-11.tar.gz ]; then \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/python-3.9.14-1-linux-${OS_ARCH}-debian-11.tar.gz -O ; \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/python-3.9.14-1-linux-${OS_ARCH}-debian-11.tar.gz.sha256 -O ; \
|
|
fi && \
|
|
sha256sum -c python-3.9.14-1-linux-${OS_ARCH}-debian-11.tar.gz.sha256 && \
|
|
tar -zxf python-3.9.14-1-linux-${OS_ARCH}-debian-11.tar.gz -C /opt/bitnami --strip-components=2 --no-same-owner --wildcards '*/files' && \
|
|
rm -rf python-3.9.14-1-linux-${OS_ARCH}-debian-11.tar.gz python-3.9.14-1-linux-${OS_ARCH}-debian-11.tar.gz.sha256
|
|
RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
|
if [ ! -f java-1.8.345-2-linux-${OS_ARCH}-debian-11.tar.gz ]; then \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/java-1.8.345-2-linux-${OS_ARCH}-debian-11.tar.gz -O ; \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/java-1.8.345-2-linux-${OS_ARCH}-debian-11.tar.gz.sha256 -O ; \
|
|
fi && \
|
|
sha256sum -c java-1.8.345-2-linux-${OS_ARCH}-debian-11.tar.gz.sha256 && \
|
|
tar -zxf java-1.8.345-2-linux-${OS_ARCH}-debian-11.tar.gz -C /opt/bitnami --strip-components=2 --no-same-owner --wildcards '*/files' && \
|
|
rm -rf java-1.8.345-2-linux-${OS_ARCH}-debian-11.tar.gz java-1.8.345-2-linux-${OS_ARCH}-debian-11.tar.gz.sha256
|
|
RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
|
if [ ! -f gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz ]; then \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz -O ; \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz.sha256 -O ; \
|
|
fi && \
|
|
sha256sum -c gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz.sha256 && \
|
|
tar -zxf gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz -C /opt/bitnami --strip-components=2 --no-same-owner --wildcards '*/files' && \
|
|
rm -rf gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz.sha256
|
|
RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
|
if [ ! -f yq-4.27.5-0-linux-${OS_ARCH}-debian-11.tar.gz ]; then \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/yq-4.27.5-0-linux-${OS_ARCH}-debian-11.tar.gz -O ; \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/yq-4.27.5-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256 -O ; \
|
|
fi && \
|
|
sha256sum -c yq-4.27.5-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256 && \
|
|
tar -zxf yq-4.27.5-0-linux-${OS_ARCH}-debian-11.tar.gz -C /opt/bitnami --strip-components=2 --no-same-owner --wildcards '*/files' && \
|
|
rm -rf yq-4.27.5-0-linux-${OS_ARCH}-debian-11.tar.gz yq-4.27.5-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256
|
|
RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
|
if [ ! -f cassandra-4.0.6-0-linux-${OS_ARCH}-debian-11.tar.gz ]; then \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/cassandra-4.0.6-0-linux-${OS_ARCH}-debian-11.tar.gz -O ; \
|
|
curl -SsLf https://downloads.bitnami.com/files/stacksmith/cassandra-4.0.6-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256 -O ; \
|
|
fi && \
|
|
sha256sum -c cassandra-4.0.6-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256 && \
|
|
tar -zxf cassandra-4.0.6-0-linux-${OS_ARCH}-debian-11.tar.gz -C /opt/bitnami --strip-components=2 --no-same-owner --wildcards '*/files' && \
|
|
rm -rf cassandra-4.0.6-0-linux-${OS_ARCH}-debian-11.tar.gz cassandra-4.0.6-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256
|
|
RUN apt-get update && apt-get upgrade -y && \
|
|
rm -r /var/lib/apt/lists /var/cache/apt/archives
|
|
RUN chmod g+rwX /opt/bitnami
|
|
RUN ln -s /opt/bitnami/scripts/cassandra/entrypoint.sh /entrypoint.sh
|
|
RUN ln -s /opt/bitnami/scripts/cassandra/run.sh /run.sh
|
|
|
|
COPY rootfs /
|
|
RUN /opt/bitnami/scripts/cassandra/postunpack.sh
|
|
RUN /opt/bitnami/scripts/java/postunpack.sh
|
|
ENV APP_VERSION="4.0.6" \
|
|
BITNAMI_APP_NAME="cassandra" \
|
|
JAVA_HOME="/opt/bitnami/java" \
|
|
PATH="/opt/bitnami/python/bin:/opt/bitnami/java/bin:/opt/bitnami/common/bin:/opt/bitnami/cassandra/bin:$PATH"
|
|
|
|
EXPOSE 7000 9042
|
|
|
|
USER 1001
|
|
ENTRYPOINT [ "/opt/bitnami/scripts/cassandra/entrypoint.sh" ]
|
|
CMD [ "/opt/bitnami/scripts/cassandra/run.sh" ]
|