Skip to content

Commit

Permalink
6.1.0.32_2
Browse files Browse the repository at this point in the history
  • Loading branch information
pvinh-spike committed Apr 26, 2024
1 parent 8d1277e commit 210b899
Show file tree
Hide file tree
Showing 13 changed files with 392 additions and 24 deletions.
40 changes: 26 additions & 14 deletions bake.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -10,36 +10,48 @@
#------------------------------------ test -----------------------------------

group "test" {
targets=["enterprise_ubuntu20-04_amd64", "community_ubuntu20-04_amd64"]
targets=["enterprise_debian11_amd64", "federal_debian11_amd64", "community_debian11_amd64"]
}

target "enterprise_ubuntu20-04_amd64" {
tags=["aerospike/aerospike-server-enterprise-amd64:5.7.0.31"]
target "enterprise_debian11_amd64" {
tags=["aerospike/aerospike-server-enterprise-amd64:6.1.0.32", "aerospike/aerospike-server-enterprise-amd64:latest"]
platforms=["linux/amd64"]
context="./enterprise/ubuntu20.04"
context="./enterprise/debian11"
}

target "community_ubuntu20-04_amd64" {
tags=["aerospike/aerospike-server-community-amd64:5.7.0.31"]
target "federal_debian11_amd64" {
tags=["aerospike/aerospike-server-federal-amd64:6.1.0.32", "aerospike/aerospike-server-federal-amd64:latest"]
platforms=["linux/amd64"]
context="./community/ubuntu20.04"
context="./federal/debian11"
}

target "community_debian11_amd64" {
tags=["aerospike/aerospike-server-community-amd64:6.1.0.32", "aerospike/aerospike-server-community-amd64:latest"]
platforms=["linux/amd64"]
context="./community/debian11"
}

#------------------------------------ push -----------------------------------

group "push" {
targets=["enterprise_ubuntu20-04", "community_ubuntu20-04"]
targets=["enterprise_debian11", "federal_debian11", "community_debian11"]
}

target "enterprise_debian11" {
tags=["aerospike/aerospike-server-enterprise:6.1.0.32", "aerospike/aerospike-server-enterprise:6.1.0.32_2"]
platforms=["linux/amd64"]
context="./enterprise/debian11"
}

target "enterprise_ubuntu20-04" {
tags=["aerospike/aerospike-server-enterprise:5.7.0.31", "aerospike/aerospike-server-enterprise:5.7.0.31_3"]
target "federal_debian11" {
tags=["aerospike/aerospike-server-federal:6.1.0.32", "aerospike/aerospike-server-federal:6.1.0.32_2"]
platforms=["linux/amd64"]
context="./enterprise/ubuntu20.04"
context="./federal/debian11"
}

target "community_ubuntu20-04" {
tags=["aerospike/aerospike-server:5.7.0.31", "aerospike/aerospike-server:5.7.0.31_3"]
target "community_debian11" {
tags=["aerospike/aerospike-server:6.1.0.32", "aerospike/aerospike-server:6.1.0.32_2"]
platforms=["linux/amd64"]
context="./community/ubuntu20.04"
context="./community/debian11"
}

Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
# http://github.com/aerospike/aerospike-server.docker
#

FROM ubuntu:20.04
FROM debian:bullseye-slim

LABEL org.opencontainers.image.title="Aerospike Community Server" \
org.opencontainers.image.description="Aerospike is a real-time database with predictable performance at petabyte scale with microsecond latency over billions of transactions." \
org.opencontainers.image.documentation="https://hub.docker.com/_/aerospike" \
org.opencontainers.image.base.name="docker.io/library/ubuntu:20.04" \
org.opencontainers.image.base.name="docker.io/library/debian:bullseye-slim" \
org.opencontainers.image.source="https://github.com/aerospike/aerospike-server.docker" \
org.opencontainers.image.vendor="Aerospike" \
org.opencontainers.image.version="5.7.0.31" \
org.opencontainers.image.version="6.1.0.32" \
org.opencontainers.image.url="https://github.com/aerospike/aerospike-server.docker"

# AEROSPIKE_EDITION - required - must be "community", "enterprise", or
Expand All @@ -23,8 +23,8 @@ LABEL org.opencontainers.image.title="Aerospike Community Server" \
# By selecting "federal" you agree to the "FEDERAL_LICENSE"
ARG AEROSPIKE_EDITION="community"

ARG AEROSPIKE_X86_64_LINK="https://artifacts.aerospike.com/aerospike-server-community/5.7.0.31/aerospike-server-community-5.7.0.31-ubuntu20.04.tgz"
ARG AEROSPIKE_SHA_X86_64="f8575e66b59a8b79995ad5f40942c89524e3fb6ded56bcd36e606d6ab411b5e1"
ARG AEROSPIKE_X86_64_LINK="https://artifacts.aerospike.com/aerospike-server-community/6.1.0.32/aerospike-server-community-6.1.0.32-debian11.tgz"
ARG AEROSPIKE_SHA_X86_64="1a54797508d7ed6fcf3c9ce5172eeeb974fef11f5c917b3f79d3b114d5747aab"
ARG AEROSPIKE_AARCH64_LINK=""
ARG AEROSPIKE_SHA_AARCH64=""

Expand Down Expand Up @@ -124,6 +124,7 @@ RUN \
}; \
{ \
# 20-install-dependencies-deb.part - Extract tools.
# ar on debian10 doesn't support '--output'
pushd aerospike/pkg || exit 1; \
ar -x ../aerospike-tools*.deb; \
popd || exit 1; \
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
# http://github.com/aerospike/aerospike-server.docker
#

FROM ubuntu:20.04
FROM debian:bullseye-slim

LABEL org.opencontainers.image.title="Aerospike Enterprise Server" \
org.opencontainers.image.description="Aerospike is a real-time database with predictable performance at petabyte scale with microsecond latency over billions of transactions." \
org.opencontainers.image.documentation="https://hub.docker.com/_/aerospike" \
org.opencontainers.image.base.name="docker.io/library/ubuntu:20.04" \
org.opencontainers.image.base.name="docker.io/library/debian:bullseye-slim" \
org.opencontainers.image.source="https://github.com/aerospike/aerospike-server.docker" \
org.opencontainers.image.vendor="Aerospike" \
org.opencontainers.image.version="5.7.0.31" \
org.opencontainers.image.version="6.1.0.32" \
org.opencontainers.image.url="https://github.com/aerospike/aerospike-server.docker"

# AEROSPIKE_EDITION - required - must be "community", "enterprise", or
Expand All @@ -23,8 +23,8 @@ LABEL org.opencontainers.image.title="Aerospike Enterprise Server" \
# By selecting "federal" you agree to the "FEDERAL_LICENSE"
ARG AEROSPIKE_EDITION="enterprise"

ARG AEROSPIKE_X86_64_LINK="https://artifacts.aerospike.com/aerospike-server-enterprise/5.7.0.31/aerospike-server-enterprise-5.7.0.31-ubuntu20.04.tgz"
ARG AEROSPIKE_SHA_X86_64="1f80b1b9fd69bce8248679401b3674736e373cbb4a641995d49574b94f04b3c6"
ARG AEROSPIKE_X86_64_LINK="https://artifacts.aerospike.com/aerospike-server-enterprise/6.1.0.32/aerospike-server-enterprise-6.1.0.32-debian11.tgz"
ARG AEROSPIKE_SHA_X86_64="9baedb2720be225336d09381fa0e8a164c4e8aef8786728e5292191500877465"
ARG AEROSPIKE_AARCH64_LINK=""
ARG AEROSPIKE_SHA_AARCH64=""

Expand Down Expand Up @@ -124,6 +124,7 @@ RUN \
}; \
{ \
# 20-install-dependencies-deb.part - Extract tools.
# ar on debian10 doesn't support '--output'
pushd aerospike/pkg || exit 1; \
ar -x ../aerospike-tools*.deb; \
popd || exit 1; \
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
199 changes: 199 additions & 0 deletions federal/debian11/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,199 @@

#
# Aerospike Server Dockerfile
#
# http://github.com/aerospike/aerospike-server.docker
#

FROM debian:bullseye-slim

LABEL org.opencontainers.image.title="Aerospike Federal Server" \
org.opencontainers.image.description="Aerospike is a real-time database with predictable performance at petabyte scale with microsecond latency over billions of transactions." \
org.opencontainers.image.documentation="https://hub.docker.com/_/aerospike" \
org.opencontainers.image.base.name="docker.io/library/debian:bullseye-slim" \
org.opencontainers.image.source="https://github.com/aerospike/aerospike-server.docker" \
org.opencontainers.image.vendor="Aerospike" \
org.opencontainers.image.version="6.1.0.32" \
org.opencontainers.image.url="https://github.com/aerospike/aerospike-server.docker"

# AEROSPIKE_EDITION - required - must be "community", "enterprise", or
# "federal".
# By selecting "community" you agree to the "COMMUNITY_LICENSE".
# By selecting "enterprise" you agree to the "ENTERPRISE_LICENSE".
# By selecting "federal" you agree to the "FEDERAL_LICENSE"
ARG AEROSPIKE_EDITION="federal"

ARG AEROSPIKE_X86_64_LINK="https://artifacts.aerospike.com/aerospike-server-federal/6.1.0.32/aerospike-server-federal-6.1.0.32-debian11.tgz"
ARG AEROSPIKE_SHA_X86_64="9d20be6070c86dcc99ba95302c11d1c59e49d96efa76281f4a231ffe7b8f2674"
ARG AEROSPIKE_AARCH64_LINK=""
ARG AEROSPIKE_SHA_AARCH64=""

SHELL ["/bin/bash", "-Eeuo", "pipefail", "-c"]

# Install Aerospike Server and Tools
RUN \
{ \
# 00-prelude-deb.part - Setup dependencies for scripts.
export DEBIAN_FRONTEND=noninteractive; \
apt-get update -y; \
apt-get install -y --no-install-recommends apt-utils; \
apt-get install -y --no-install-recommends \
binutils \
ca-certificates \
curl \
xz-utils; \
}; \
{ \
# 00-prelude-deb.part - Install procps for tests.
apt-get install -y --no-install-recommends procps; \
}; \
{ \
# 10-download.part - Vars used for tini and tools.
VERSION="$(grep -oE "/[0-9]+[.][0-9]+[.][0-9]+([.][0-9]+)+(-rc[0-9]+)?([-][0-9]+[-]g[0-9a-z]*)?/" <<<"${AEROSPIKE_X86_64_LINK}" | tr -d '/' | tail -1)"; \
}; \
{ \
# 10-common.part - Install tini.
ARCH="$(dpkg --print-architecture)"; \
if [ "${ARCH}" = "amd64" ]; then \
sha256=d1f6826dd70cdd88dde3d5a20d8ed248883a3bc2caba3071c8a3a9b0e0de5940; \
suffix=""; \
elif [ "${ARCH}" = "arm64" ]; then \
sha256=1c398e5283af2f33888b7d8ac5b01ac89f777ea27c85d25866a40d1e64d0341b; \
suffix="-arm64"; \
else \
echo "Unsuported architecture - ${ARCH}" >&2; \
exit 1; \
fi; \
curl -fsSL "https://github.com/aerospike/tini/releases/download/1.0.1/as-tini-static${suffix}" --output /usr/bin/as-tini-static; \
echo "${sha256} /usr/bin/as-tini-static" | sha256sum -c -; \
chmod +x /usr/bin/as-tini-static; \
}; \
{ \
# 10-download.part - Download server and tools.
ARCH="$(dpkg --print-architecture)"; \
mkdir -p aerospike/pkg; \
if [ "${ARCH}" = "amd64" ]; then \
pkg_link="${AEROSPIKE_X86_64_LINK}"; \
sha256="${AEROSPIKE_SHA_X86_64}"; \
elif [ "${ARCH}" = "arm64" ]; then \
pkg_link="${AEROSPIKE_AARCH64_LINK}"; \
sha256="${AEROSPIKE_SHA_AARCH64}"; \
else \
echo "Unsuported architecture - ${ARCH}" >&2; \
exit 1; \
fi; \
if ! curl -fsSL "${pkg_link}" --output aerospike-server.tgz; then \
echo "Could not fetch pkg - ${pkg_link}" >&2; \
exit 1; \
fi; \
echo "${sha256} aerospike-server.tgz" | sha256sum -c -; \
tar xzf aerospike-server.tgz --strip-components=1 -C aerospike; \
rm aerospike-server.tgz; \
# These directories are required for backward compatibility.
mkdir -p /var/{log,run}/aerospike; \
# Copy license file to standard location.
mkdir -p /licenses; \
cp aerospike/LICENSE /licenses; \
}; \
{ \
# 20-install-dependencies-deb.part - Install server and dependencies.
if [ "${AEROSPIKE_EDITION}" = "enterprise" ]; then \
apt-get install -y --no-install-recommends \
libcurl4 \
libldap-2.4.2; \
elif ! [ "$(printf "%s\n%s" "${VERSION}" "6.0" | sort -V | head -1)" != "${VERSION}" ]; then \
apt-get install -y --no-install-recommends \
libcurl4; \
fi; \
dpkg -i aerospike/aerospike-server-*.deb; \
rm -rf /opt/aerospike/bin; \
}; \
{ \
# 20-install-dependencies-deb.part - Install tools dependencies.
if ! [ "$(printf "%s\n%s" "${VERSION}" "5.1" | sort -V | head -1)" != "${VERSION}" ]; then \
# Tools before 5.1 need python2.
apt-get install -y --no-install-recommends \
python2; \
elif ! [ "$(printf "%s\n%s" "${VERSION}" "6.2.0.3" | sort -V | head -1)" != "${VERSION}" ]; then \
# Tools before 6.0 need python3.
apt-get install -y --no-install-recommends \
python3 \
python3-distutils; \
fi; \
# Tools after 6.0 bundled their own python interpreter.
}; \
{ \
# 20-install-dependencies-deb.part - Extract tools.
# ar on debian10 doesn't support '--output'
pushd aerospike/pkg || exit 1; \
ar -x ../aerospike-tools*.deb; \
popd || exit 1; \
tar xf aerospike/pkg/data.tar.xz -C aerospike/pkg/; \
}; \
{ \
# 30-install-tools.part - install asinfo and asadm.
find aerospike/pkg/opt/aerospike/bin/ -user aerospike -group aerospike -exec chown root:root {} +; \
mv aerospike/pkg/etc/aerospike/astools.conf /etc/aerospike; \
if ! [ "$(printf "%s\n%s" "${VERSION}" "6.2" | sort -V | head -1)" != "${VERSION}" ]; then \
mv aerospike/pkg/opt/aerospike/bin/aql /usr/bin; \
fi; \
if [ -d 'aerospike/pkg/opt/aerospike/bin/asadm' ]; then \
# Since tools release 7.0.5, asadm has been moved from
# /opt/aerospike/bin/asadm to /opt/aerospike/bin/asadm/asadm
# (inside an asadm directory).
mv aerospike/pkg/opt/aerospike/bin/asadm /usr/lib/; \
else \
mkdir /usr/lib/asadm; \
mv aerospike/pkg/opt/aerospike/bin/asadm /usr/lib/asadm/; \
fi; \
ln -s /usr/lib/asadm/asadm /usr/bin/asadm; \
if [ -f 'aerospike/pkg/opt/aerospike/bin/asinfo' ]; then \
# Since tools release 7.1.1, asinfo has been moved from
# /opt/aerospike/bin/asinfo to /opt/aerospike/bin/asadm/asinfo
# (inside an asadm directory).
mv aerospike/pkg/opt/aerospike/bin/asinfo /usr/lib/asadm/; \
fi; \
ln -s /usr/lib/asadm/asinfo /usr/bin/asinfo; \
}; \
{ \
# 40-cleanup.part - remove extracted aerospike pkg directory.
rm -rf aerospike; \
}; \
{ \
# 50-remove-prelude-deb.part - Remove dependencies for scripts.
rm -rf /var/lib/apt/lists/*; \
dpkg --purge \
apt-utils \
binutils \
ca-certificates \
curl \
xz-utils 2>&1; \
apt-get purge -y; \
apt-get autoremove -y; \
unset DEBIAN_FRONTEND; \
}; \
echo "done";

# Add the Aerospike configuration specific to this dockerfile
COPY aerospike.template.conf /etc/aerospike/aerospike.template.conf

# Mount the Aerospike data directory
# VOLUME ["/opt/aerospike/data"]
# Mount the Aerospike config directory
# VOLUME ["/etc/aerospike/"]

# Expose Aerospike ports
#
# 3000 – service port, for client connections
# 3001 – fabric port, for cluster communication
# 3002 – mesh port, for cluster heartbeat
#
EXPOSE 3000 3001 3002

COPY entrypoint.sh /entrypoint.sh

# Tini init set to restart ASD on SIGUSR1 and terminate ASD on SIGTERM
ENTRYPOINT ["/usr/bin/as-tini-static", "-r", "SIGUSR1", "-t", "SIGTERM", "--", "/entrypoint.sh"]

# Execute the run script in foreground mode
CMD ["asd"]
5 changes: 5 additions & 0 deletions federal/debian11/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Dockerfile Template

These files are managed by `update.sh`, do not edit files outside of the `template` directory.

After updating files in the `template` directory, be sure to run `update.sh` before committing.
Loading

0 comments on commit 210b899

Please sign in to comment.