Open vityaman opened 1 week ago
I failed to build the Restler Docker image locally using instructions provided in README.
# Clone the repo git clone git@github.com:microsoft/restler-fuzzer.git cd restler-fuzzer # Check project version git log --name-status HEAD^..HEAD # commit 694cc9e63dc61b372ddab5c6648223e4329ee6fa # Try to build an image docker build -t restler .
I expected a successfully built Docker image, that I will be able to use locally.
[+] Building 3.9s (15/16) docker:default => [internal] load build definition from Dockerfile 0.0s => => transferring dockerfile: 472B 0.0s => [internal] load metadata for mcr.microsoft.com/dotnet/aspnet:6.0-alpine 0.7s => [internal] load metadata for mcr.microsoft.com/dotnet/sdk:6.0-alpine 0.6s => [internal] load .dockerignore 0.0s => => transferring context: 2B 0.0s => [target 1/4] FROM mcr.microsoft.com/dotnet/aspnet:6.0-alpine@sha256:a48a7a54f543d1824bec45d65fe039659f727681a68f44e 0.0s => [builder 1/7] FROM mcr.microsoft.com/dotnet/sdk:6.0-alpine@sha256:5c1cfd0241d775caf2c396a6de5fc9efe4260cdc31f19f2ef 0.0s => [internal] load build context 0.1s => => transferring context: 36.48kB 0.0s => CACHED [target 2/4] RUN apk add --no-cache python3 py3-pip 0.0s => ERROR [target 3/4] RUN pip3 install requests applicationinsights 3.0s => CACHED [builder 2/7] RUN apk add --no-cache python3 py3-pip 0.0s => CACHED [builder 3/7] COPY src ./src 0.0s => CACHED [builder 4/7] COPY restler ./restler 0.0s => CACHED [builder 5/7] COPY build-restler.py . 0.0s => CACHED [builder 6/7] RUN python3 build-restler.py --dest_dir /build 0.0s => CACHED [builder 7/7] RUN python3 -m compileall -b /build/engine 0.0s ------ > [target 3/4] RUN pip3 install requests applicationinsights: 2.130 error: externally-managed-environment 2.130 2.130 × This environment is externally managed 2.130 ╰─> 2.130 The system-wide python installation should be maintained using the system 2.130 package manager (apk) only. 2.130 2.130 If the package in question is not packaged already (and hence installable via 2.130 "apk add py3-somepackage"), please consider installing it inside a virtual 2.130 environment, e.g.: 2.130 2.130 python3 -m venv /path/to/venv 2.130 . /path/to/venv/bin/activate 2.130 pip install mypackage 2.130 2.130 To exit the virtual environment, run: 2.130 2.130 deactivate 2.130 2.130 The virtual environment is not deleted, and can be re-entered by re-sourcing 2.130 the activate file. 2.130 2.130 To automatically manage virtual environments, consider using pipx (from the 2.130 pipx package). 2.130 2.130 note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages. 2.130 hint: See PEP 668 for the detailed specification. ------ Dockerfile:16 -------------------- 14 | 15 | RUN apk add --no-cache python3 py3-pip 16 | >>> RUN pip3 install requests applicationinsights 17 | 18 | COPY --from=builder /build /RESTler -------------------- ERROR: failed to solve: process "/bin/sh -c pip3 install requests applicationinsights" did not complete successfully: exit code: 1
Linux, Docker 26.1.3
Workaround: https://github.com/vityaman/restler-fuzzer/pull/1
I am also seeing same error on Mac OS
I am seeing the same error on Windows 10
Description
I failed to build the Restler Docker image locally using instructions provided in README.
Steps to reproduce
Expected results
I expected a successfully built Docker image, that I will be able to use locally.
Actual results
Environment details
Linux, Docker 26.1.3