Skip to content

Commit

Permalink
feat(tikv): add dwz tool into builder images (#523)
Browse files Browse the repository at this point in the history
Signed-off-by: wuhuizuo <wuhuizuo@126.com>
  • Loading branch information
wuhuizuo authored Jan 8, 2025
1 parent 738ed49 commit b22476a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 19 deletions.
5 changes: 2 additions & 3 deletions dockerfiles/cd/builders/tikv/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,12 @@ LABEL org.opencontainers.image.authors "wuhui.zuo@pingcap.com"
LABEL org.opencontainers.image.description "binary builder for TiKV"
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"

# install packages.
# install packages.
RUN --mount=type=cache,target=/var/cache/dnf \
dnf upgrade-minimal -y && \
dnf --enablerepo=powertools install -y \
make git findutils gcc gcc-c++ cmake curl openssl-devel perl python3 \
libstdc++-static
git findutils gcc gcc-c++ make cmake curl dwz openssl-devel perl python3 \
libstdc++-static

# install protoc.
# renovate: datasource=github-release depName=protocolbuffers/protobuf
Expand Down
2 changes: 1 addition & 1 deletion dockerfiles/cd/builders/tikv/centos7/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ RUN yum install --nogpgcheck -y epel-release centos-release-scl deltarpm && \
sed -i s/^mirrorlist=http/#mirrorlist=http/g /etc/yum.repos.d/*.repo && \
([ "$(arch)" = "x86_64" ] || sed -i s#vault.centos.org/centos/7/sclo/#vault.centos.org/altarch/7/sclo/#g /etc/yum.repos.d/*.repo) && \
yum update --nogpgcheck -y && \
yum install -y git devtoolset-${DEVTOOLSET_VER} perl cmake3 unzip && \
yum install -y git devtoolset-${DEVTOOLSET_VER} perl cmake3 unzip dwz && \
yum clean all && \
ln -s /usr/bin/cmake3 /usr/bin/cmake
ENV DEVTOOLSET_VER ${DEVTOOLSET_VER}
Expand Down
20 changes: 5 additions & 15 deletions dockerfiles/cd/builders/tikv/fips.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,10 @@ LABEL org.opencontainers.image.description "binary builder for TiKV with FIPS su
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"

# install packages.
RUN dnf install -y \
openssl-devel \
gcc \
gcc-c++ \
make \
cmake \
perl \
git \
findutils \
curl \
python3 --allowerasing \
&& dnf --enablerepo=crb install -y libstdc++-static \
&& dnf clean all \
&& rm -Rf /var/cache/dnf
RUN --mount=type=cache,target=/var/cache/dnf \
dnf --enablerepo=crb install -y --allowerasing \
git findutils gcc gcc-c++ make cmake dwz curl openssl-devel perl python3 \
libstdc++-static

# install protoc.
# renovate: datasource=github-release depName=protocolbuffers/protobuf
Expand All @@ -41,7 +31,7 @@ ENV PATH /root/.cargo/bin/:$PATH
FROM builder as building
COPY . /ws
RUN --mount=type=cache,target=/tikv/target \
ENABLE_FIPS=1 ROCKSDB_SYS_STATIC=1 make dist_release -C /ws
ENABLE_FIPS=1 ROCKSDB_SYS_STATIC=1 make dist_release -C /ws
RUN /ws/bin/tikv-server --version

########### stage: Final image
Expand Down

0 comments on commit b22476a

Please sign in to comment.