github.com/lzhfromustc/gofuzz@v0.0.0-20211116160056-151b3108bbd1/mount.Dockerfile (about) 1 # TODO: use multi-stage build to reduce image size 2 # TODO: extend from built goFuzz base to remove duplicated logic 3 FROM golang:1.16.4 4 5 RUN apt update && apt install -y python3 6 7 WORKDIR /gofuzz 8 9 # copy source files to docker 10 COPY goFuzz ./goFuzz 11 COPY sync ./sync 12 COPY runtime ./runtime 13 COPY scripts ./scripts 14 COPY time ./time 15 COPY reflect ./reflect 16 RUN cd goFuzz && make build 17 18 # Patch golang runtime in the container 19 RUN chmod +x scripts/patch-go-runtime.sh \ 20 && ./scripts/patch-go-runtime.sh 21 22 WORKDIR /gofuzz/goFuzz 23 24 # RUN groupadd gfgroup 25 # RUN useradd --create-home -r -u 1001 -g gfgroup gfuser 26 # RUN chown gfuser:gfgroup ./scripts/fuzz.sh && chmod +x ./scripts/fuzz.sh 27 # USER gfuser 28 29 RUN chmod +x ./scripts/fuzz.sh 30 ENTRYPOINT [ "scripts/fuzz.sh" ]