Skip to content

Commit 362763d

Browse files
committed
Sandbox: add Cloudberry 2.1.0 release support
Main changes: - Update default CODEBASE_VERSION from 2.0.0 to 2.1.0 in .env - Update documentation examples to use version 2.1.0 in README.md - Update help message example version in run.sh - Switch to Apache mirror system for downloading release tarball using closer.lua for better download reliability and speed - Replace wget with curl for source download in Dockerfile This change ensures the sandbox environment defaults to the latest Apache Cloudberry 2.1.0 release and uses the recommended Apache mirror download method.
1 parent 56dd541 commit 362763d

4 files changed

Lines changed: 13 additions & 47 deletions

File tree

devops/sandbox/.env

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,5 @@
1717
# permissions and limitations under the License.
1818
#
1919
# --------------------------------------------------------------------
20-
CODEBASE_VERSION=2.0.0
20+
CODEBASE_VERSION=2.1.0
2121
OS_VERSION=rockylinux9

devops/sandbox/Dockerfile.RELEASE.rockylinux9

Lines changed: 9 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,7 @@ RUN dnf makecache && \
9494
readline-devel \
9595
zlib-devel && \
9696
dnf install -y --enablerepo=crb \
97+
liburing-devel \
9798
libuv-devel \
9899
libyaml-devel \
99100
perl-IPC-Run \
@@ -120,58 +121,22 @@ USER gpadmin
120121
WORKDIR /home/gpadmin
121122

122123
# Release version to build (Apache official tarball)
123-
ARG CB_RELEASE_VERSION=2.0.0-incubating
124+
ARG CB_RELEASE_VERSION=2.1.0-incubating
124125

125126
# Download and extract the specified release version from Apache
126-
RUN wget -nv "https://downloads.apache.org/incubator/cloudberry/${CB_RELEASE_VERSION}/apache-cloudberry-${CB_RELEASE_VERSION}-src.tar.gz" -O /home/gpadmin/apache-cloudberry-${CB_RELEASE_VERSION}-src.tar.gz && \
127+
# Using Apache mirror system for better download reliability and speed
128+
RUN curl -L -o /home/gpadmin/apache-cloudberry-${CB_RELEASE_VERSION}-src.tar.gz \
129+
"https://www.apache.org/dyn/closer.lua/incubator/cloudberry/${CB_RELEASE_VERSION}/apache-cloudberry-${CB_RELEASE_VERSION}-src.tar.gz?action=download" && \
127130
tar -xzf /home/gpadmin/apache-cloudberry-${CB_RELEASE_VERSION}-src.tar.gz -C /home/gpadmin && \
128131
rm -f /home/gpadmin/apache-cloudberry-${CB_RELEASE_VERSION}-src.tar.gz && \
129132
mv /home/gpadmin/apache-cloudberry-${CB_RELEASE_VERSION} /home/gpadmin/cloudberry
130133

131134
# Build Cloudberry using the official build scripts
132135
RUN cd /home/gpadmin/cloudberry && \
133136
export SRC_DIR=/home/gpadmin/cloudberry && \
134-
mkdir -p "${SRC_DIR}/build-logs" && \
135-
# Ensure Cloudberry lib dir exists and has Xerces libs available
136-
sudo rm -rf /usr/local/cloudberry-db && \
137-
sudo mkdir -p /usr/local/cloudberry-db/lib && \
138-
sudo cp -v /usr/local/xerces-c/lib/libxerces-c.so \
139-
/usr/local/xerces-c/lib/libxerces-c-3.*.so \
140-
/usr/local/cloudberry-db/lib/ && \
141-
sudo chown -R gpadmin:gpadmin /usr/local/cloudberry-db && \
142-
# Configure with required features and paths
143-
export LD_LIBRARY_PATH=/usr/local/cloudberry-db/lib:$LD_LIBRARY_PATH && \
144-
./configure --prefix=/usr/local/cloudberry-db \
145-
--disable-external-fts \
146-
--enable-debug \
147-
--enable-cassert \
148-
--enable-debug-extensions \
149-
--enable-gpcloud \
150-
--enable-ic-proxy \
151-
--enable-mapreduce \
152-
--enable-orafce \
153-
--enable-orca \
154-
--enable-pax \
155-
--disable-pxf \
156-
--enable-tap-tests \
157-
--with-gssapi \
158-
--with-ldap \
159-
--with-libxml \
160-
--with-lz4 \
161-
--with-pam \
162-
--with-perl \
163-
--with-pgport=5432 \
164-
--with-python \
165-
--with-pythonsrc-ext \
166-
--with-ssl=openssl \
167-
--with-uuid=e2fs \
168-
--with-includes=/usr/local/xerces-c/include \
169-
--with-libraries=/usr/local/cloudberry-db/lib && \
170-
# Build and install
171-
make -j$(nproc) --directory ${SRC_DIR} && \
172-
make -j$(nproc) --directory ${SRC_DIR}/contrib && \
173-
make install --directory ${SRC_DIR} && \
174-
make install --directory "${SRC_DIR}/contrib"
137+
mkdir -p ${SRC_DIR}/build-logs && \
138+
./devops/build/automation/cloudberry/scripts/configure-cloudberry.sh && \
139+
./devops/build/automation/cloudberry/scripts/build-cloudberry.sh
175140

176141
# --------------------------------------------------------------------
177142
# Runtime stage: Rocky Linux 9 runtime with required dependencies
@@ -192,6 +157,7 @@ RUN dnf -y update && \
192157
krb5-libs \
193158
libevent \
194159
libicu \
160+
liburing \
195161
libuuid \
196162
libxml2 \
197163
libyaml \

devops/sandbox/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,14 +92,14 @@ Build and deploy steps:
9292

9393
```shell
9494
cd cloudberry/devops/sandbox
95-
./run.sh -c 2.0.0
95+
./run.sh -c 2.1.0
9696
```
9797

9898
- For latest Apache Cloudberry release running across multiple containers
9999

100100
```shell
101101
cd cloudberry/devops/sandbox
102-
./run.sh -c 2.0.0 -m
102+
./run.sh -c 2.1.0 -m
103103
```
104104

105105
- For latest main branch running on a single container

devops/sandbox/run.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ PIP_INDEX_URL_VAR="${PIP_INDEX_URL_VAR:-$DEFAULT_PIP_INDEX_URL_VAR}"
3838
# Function to display help message
3939
function usage() {
4040
echo "Usage: $0 [-o <os_version>] [-c <codebase_version>] [-b] [-m]"
41-
echo " -c Codebase version (valid values: main, local, or other available version like 2.0.0)"
41+
echo " -c Codebase version (valid values: main, local, or other available version like 2.1.0)"
4242
echo " -t Timezone (default: America/Los_Angeles, or set via TIMEZONE_VAR environment variable)"
4343
echo " -p Python Package Index (PyPI) (default: https://pypi.org/simple, or set via PIP_INDEX_URL_VAR environment variable)"
4444
echo " -b Build only, do not run the container (default: false, or set via BUILD_ONLY environment variable)"

0 commit comments

Comments
 (0)