github.com/google/syzkaller@v0.0.0-20251211124644-a066d2bc4b02/syz-cluster/workflow/fuzz-step/Dockerfile (about)

     1  # syntax=docker.io/docker/dockerfile:1.7-labs
     2  # Copyright 2025 syzkaller project authors. All rights reserved.
     3  # Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
     4  
     5  FROM gcr.io/syzkaller/env AS fuzz-step-builder
     6  WORKDIR /build
     7  
     8  # Copy the code and the dependencies.
     9  COPY go.mod go.sum ./
    10  RUN go mod download
    11  COPY . .
    12  RUN make TARGETARCH=amd64
    13  COPY syz-cluster/ syz-cluster/
    14  RUN GO_FLAGS=$(make go-flags 2>/dev/null) && go build "$GO_FLAGS" -o /bin/fuzz-step /build/syz-cluster/workflow/fuzz-step
    15  
    16  FROM debian:bookworm
    17  
    18  RUN apt-get update && \
    19      apt-get install -y qemu-system openssh-client curl cpp gcc
    20  
    21  # Install clang tools.
    22  RUN apt-get install -y -q gnupg software-properties-common apt-transport-https
    23  RUN curl https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add -
    24  RUN echo "deb http://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-20 main" | tee /etc/apt/sources.list.d/llvm-20.list
    25  RUN apt-get update --allow-releaseinfo-change
    26  RUN apt-get install -y -q --no-install-recommends llvm-20 clang-20 clang-format-20
    27  RUN update-alternatives --install /usr/bin/clang clang /usr/bin/clang-20 100
    28  RUN update-alternatives --install /usr/bin/llvm-addr2line llvm-addr2line /usr/bin/llvm-addr2line-20 100
    29  RUN update-alternatives --install /usr/bin/clang-format clang-format /usr/bin/clang-format-20 100
    30  
    31  # pkg/osutil uses syzkaller user for sandboxing.
    32  RUN useradd --create-home syzkaller
    33  
    34  COPY --from=fuzz-step-builder /build/bin/ /syzkaller/bin/
    35  COPY --from=fuzz-step-builder /bin/fuzz-step /bin/fuzz-step
    36  
    37  ENTRYPOINT ["/bin/fuzz-step"]