Skip to content

Commit

Permalink
reduce number of layers
Browse files Browse the repository at this point in the history
  • Loading branch information
xxchan committed Sep 17, 2023
1 parent bfaacba commit 9c3d3d1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@ ARG GIT_SHA
ENV GIT_SHA=$GIT_SHA

COPY ./ /risingwave
RUN cargo fetch
RUN cargo build -p risingwave_cmd_all --release --features "rw-static-link"
RUN mkdir -p /risingwave/bin && \
RUN cargo fetch && \
cargo build -p risingwave_cmd_all --release --features "rw-static-link" && \
mkdir -p /risingwave/bin && \
mv /risingwave/target/release/risingwave /risingwave/bin/ && \
mv /risingwave/target/release/risingwave.dwp /risingwave/bin/ && \
cp ./target/release/build/tikv-jemalloc-sys-*/out/build/bin/jeprof /risingwave/bin/ && \
Expand Down Expand Up @@ -92,8 +92,8 @@ RUN mvn dependency:go-offline --fail-never
# Besides, rust-maven-plugin sets --target-dir, so the dependencies are built twice. How to dedup?
COPY ./ /risingwave

RUN mvn -B package -Dmaven.test.skip=true -Djava.binding.release=true
RUN mkdir -p /risingwave/bin/connector-node && \
RUN mvn -B package -Dmaven.test.skip=true -Djava.binding.release=true && \
mkdir -p /risingwave/bin/connector-node && \
tar -zxvf /risingwave/java/connector-node/assembly/target/risingwave-connector-1.0.0.tar.gz -C /risingwave/bin/connector-node

FROM base AS risingwave
Expand Down

0 comments on commit 9c3d3d1

Please sign in to comment.