Skip to content

error of 'Containerize an application'  #326

@first-coding

Description

@first-coding

As a beginner of docker,I followed the tutorials on the official website and found that there was a mistake which i could not solve by myself.please teach me how to solve this prolem,thank you .
The following is the error report.

=> ERROR [4/4] RUN yarn install --production 225.4s

[4/4] RUN yarn install --production:
#9 0.564 yarn install v1.22.19
#9 0.646 [1/4] Resolving packages...
#9 0.886 [2/4] Fetching packages...
#9 223.7 [3/4] Linking dependencies...
#9 224.7 [4/4] Building fresh packages...
#9 225.3 error /app/node_modules/sqlite3: Command failed.
#9 225.3 Exit code: 1
#9 225.3 Command: node-pre-gyp install --fallback-to-build
#9 225.3 Arguments:
#9 225.3 Directory: /app/node_modules/sqlite3
#9 225.3 Output:
#9 225.3 node-pre-gyp info it worked if it ends with ok
#9 225.3 node-pre-gyp info using node-pre-gyp@1.0.10
#9 225.3 node-pre-gyp info using node@18.12.1 | linux | x64
#9 225.3 node-pre-gyp info check checked for "/app/node_modules/sqlite3/lib/binding/napi-v6-linux-musl-x64/node_sqlite3.node" (not found)
#9 225.3 node-pre-gyp http GET https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.2/napi-v6-linux-musl-x64.tar.gz
#9 225.3 node-pre-gyp ERR! install request to https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.2/napi-v6-linux-musl-x64.tar.gz failed, reason: connect ECONNREFUSED 127.0.0.1:443
#9 225.3 node-pre-gyp WARN Pre-built binaries not installable for sqlite3@5.1.2 and node@18.12.1 (node-v108 ABI, musl) (falling back to source compile with node-gyp)
#9 225.3 node-pre-gyp WARN Hit error request to https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.2/napi-v6-linux-musl-x64.tar.gz failed, reason: connect ECONNREFUSED 127.0.0.1:443
#9 225.3 gyp info it worked if it ends with ok
#9 225.3 gyp info using node-gyp@8.4.1
#9 225.3 gyp info using node@18.12.1 | linux | x64
#9 225.3 gyp info ok
#9 225.3 gyp info it worked if it ends with ok
#9 225.3 gyp info using node-gyp@8.4.1
#9 225.3 gyp info using node@18.12.1 | linux | x64
#9 225.3 gyp ERR! find Python
#9 225.3 gyp ERR! find Python Python is not set from command line or npm configuration
#9 225.3 gyp ERR! find Python Python is not set from environment variable PYTHON
#9 225.3 gyp ERR! find Python checking if "python3" can be used
#9 225.3 gyp ERR! find Python - "python3" is not in PATH or produced an error
#9 225.3 gyp ERR! find Python checking if "python" can be used
#9 225.3 gyp ERR! find Python - "python" is not in PATH or produced an error
#9 225.3 gyp ERR! find Python
#9 225.3 gyp ERR! find Python **********************************************************
#9 225.3 gyp ERR! find Python You need to install the latest version of Python.
#9 225.3 gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
#9 225.3 gyp ERR! find Python you can try one of the following options:
#9 225.3 gyp ERR! find Python - Use the switch --python="/path/to/pythonexecutable"
#9 225.3 gyp ERR! find Python (accepted by both node-gyp and npm)
#9 225.3 gyp ERR! find Python - Set the environment variable PYTHON
#9 225.3 gyp ERR! find Python - Set the npm configuration variable python:
#9 225.3 gyp ERR! find Python npm config set python "/path/to/pythonexecutable"
#9 225.3 gyp ERR! find Python For more information consult the documentation at:
#9 225.3 gyp ERR! find Python https://github.com/nodejs/node-gyp#installation
#9 225.3 gyp ERR! find Python **********************************************************
#9 225.3 gyp ERR! find Python
#9 225.3 gyp ERR! configure error
#9 225.3 gyp ERR! stack Error: Could not find any Python installation to use
#9 225.3 gyp ERR! stack at PythonFinder.fail (/app/node_modules/node-gyp/lib/find-python.js:330:47)
#9 225.3 gyp ERR! stack at PythonFinder.runChecks (/app/node_modules/node-gyp/lib/find-python.js:159:21)
#9 225.3 gyp ERR! stack at PythonFinder. (/app/node_modules/node-gyp/lib/find-python.js:202:16)
#9 225.3 gyp ERR! stack at PythonFinder.execFileCallback (/app/node_modules/node-gyp/lib/find-python.js:294:16)
#9 225.3 gyp ERR! stack at exithandler (node:child_process:420:5)
#9 225.3 gyp ERR! stack at ChildProcess.errorhandler (node:child_process:432:5)
#9 225.3 gyp ERR! stack at ChildProcess.emit (node:events:513:28)
#9 225.3 gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:289:12)
#9 225.3 gyp ERR! stack at onErrorNT (node:internal/child_process:476:16)
#9 225.3 gyp ERR! stack at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
#9 225.3 gyp ERR! System Linux 5.10.102.1-microsoft-standard-WSL2
#9 225.3 gyp ERR! command "/usr/local/bin/node" "/app/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--module=/app/node_modules/sqlite3/lib/binding/napi-v6-linux-musl-x64/node_sqlite3.node" "--module_name=node_sqlite3" "--module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-linux-musl-x64" "--napi_version=8" "--node_abi_napi=napi" "--napi_build_version=6" "--node_napi_label=napi-v6"
#9 225.3 gyp ERR! cwd /app/node_modules/sqlite3
#9 225.3 gyp ERR! node -v v18.12.1
#9 225.3 gyp ERR! node-gyp -v v8.4.1
#9 225.3 gyp ERR! not ok
#9 225.3 node-pre-gyp ERR! build error
#9 225.3 node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /app/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/app/node_modules/sqlite3/lib/binding/napi-v6-linux-musl-x64/node_sqlite3.node --module_name=node_sqlite3 --module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-linux-musl-x64 --napi_version=8 --node_abi_napi=napi --napi_build_version=6 --node_napi_label=napi-v6' (1)
#9 225.3 node-pre-gyp ERR! stack at ChildProcess. (/app/node_modules/@mapbox/node-pre-gyp/lib/util/compile.js:89:23)
#9 225.3 node-pre-gyp ERR! stack at ChildProcess.emit (node:events:513:28)
#9 225.3 node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1091:16)
#9 225.3 node-pre-gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:302:5)
#9 225.3 node-pre-gyp ERR! System Linux 5.10.102.1-microsoft-standard-WSL2
#9 225.3 node-pre-gyp ERR! command "/usr/local/bin/node" "/app/node_modules/sqlite3/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
#9 225.3 node-pre-gyp ERR! cwd /app/node_modules/sqlite3
#9 225.3 node-pre-gyp ERR! node -v v18.12.1
#9 225.3 node-pre-gyp ERR! node-pre-gyp -v v1.0.10
#9 225.3 node-pre-gyp ERR! not ok
#9 225.3 Failed to execute '/usr/local/bin/node /app/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/app/node_modules/sqlite3/lib/binding/napi-v6-linux-musl-x64/node_sqlite3.node --module_name=node_sqlite3 --module_path=/app/node_modules/sqlite3/lib/binding/napi-v6-linux-musl-x64 --napi_version=8 --node_abi_napi=napi --napi_build_version=6 --node_napi_label=napi-v6' (1)
#9 225.3 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.


executor failed running [/bin/sh -c yarn install --production]: exit code: 1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions