Skip to content

Commit

Permalink
ci: enable shallow clone in docker image generation to reduce image size
Browse files Browse the repository at this point in the history
Signed-off-by: Huaqi Fang <[email protected]>
  • Loading branch information
fanghuaqi committed Nov 24, 2023
1 parent ed5773e commit 65d441e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/linuxsdk.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,14 @@ ENV PATH "/home/$USER/prebuilt/qemu/bin:$PATH"

RUN ldd `which qemu-system-riscv64`

RUN git clone -b $BRANCH https://github.com/Nuclei-Software/nuclei-linux-sdk
# do shallow clone for main repo
RUN git clone --depth 10 -b $BRANCH https://github.com/Nuclei-Software/nuclei-linux-sdk

# gitee mirror no longer works
#RUN cd nuclei-linux-sdk && git remote add gitee https://gitee.com/Nuclei-Software/nuclei-linux-sdk

RUN cd nuclei-linux-sdk && git submodule init && git submodule update --recursive --init
# only do shallow clone for submodule to reduce clone size
RUN cd nuclei-linux-sdk && git submodule init && git submodule update --recursive --init --depth 10

RUN cd nuclei-linux-sdk && make freeloader bootimages

Expand Down

0 comments on commit 65d441e

Please sign in to comment.