Not able to install with yarn 4.1
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- docker, node.js
- Lĩnh vực
- build-system, devops
Hướng nghiên cứu
Tái hiện quá trình build Dockerfile bằng package.json và yarn.lock được cung cấp, sau đó kiểm tra quá trình build node-gyp của aws-lambda-ric và lời gọi binding.gyp của nó. Lỗi được báo cáo là thiếu lệnh deps/artifacts/bin/curl-config; được xem là hoàn tất khi yarn add aws-lambda-ric hoàn tất thành công trong môi trường được cung cấp.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
I'm encountering an error while trying to include the runtime interface client in my Dockerfile while using yarn 4.1.
Here is the Dockerfile:
FROM --platform=linux/amd64 node:20.9.0-bookworm-slim as install-deps
ENV APP_DIR /usr/src/app
# Install aws-lambda-cpp build dependencies
RUN apt-get update && \
apt-get install -y \
g++ \
make \
cmake \
unzip \
libcurl4-openssl-dev \
automake \
autoconf \
libtool \
cmake \
curl \
openssl \
groff \
less \
libssl-dev \
python3
RUN mkdir -p ${APP_DIR}
WORKDIR ${APP_DIR}
# uses curl, unzip, groff, less
RUN curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
RUN unzip awscliv2.zip && ./aws/install
COPY package.json yarn.lock ${APP_DIR}/
RUN corepack enable
RUN yarn install --frozen-lockfile
RUN yarn add aws-lambda-ric
I stripped down my existing package.json to remove all dependencies in an attempt to isolate the error. Here is the empty package.json:
{
"name": "test_lambda_ric",
"packageManager": "yarn@4.1.0",
"type": "module",
"license": "UNLICENSED"
}
Produces this error when running docker build:
Step 11/11 : RUN yarn add aws-lambda-ric
---> [Warning] The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
---> Running in dc2861551502
➤ YN0000: · Yarn 4.1.0
➤ YN0000: ┌ Resolution step
➤ YN0085: │ + aws-lambda-ric@npm:3.1.0, @isaacs/cliui@npm:8.0.2, @npmcli/agent@npm:2.2.2, @npmcli/fs@npm:3.1.0, @pkgjs/parseargs@npm:0.11.0, and 129 more.
➤ YN0000: └ Completed in 0s 644ms
➤ YN0000: ┌ Fetch step
➤ YN0013: │ 134 packages were added to the project (+ 13.68 MiB).
➤ YN0000: └ Completed in 1s 584ms
➤ YN0000: ┌ Link step
➤ YN0000: │ ESM support for PnP uses the experimental loader API and is therefore experimental
➤ YN0007: │ aws-lambda-ric@npm:3.1.0 must be built because it never has been before or the last one failed
➤ YN0009: │ aws-lambda-ric@npm:3.1.0 couldn't be built successfully (exit code 1, logs can be found here: /tmp/xfs-78b8e02d/build.log)
➤ YN0000: └ Completed in 5m 39s
➤ YN0000: · Failed with errors in 5m 41s
The log file contains this error:
# This file contains the result of Yarn building a package (aws-lambda-ric@npm:3.1.0)
# Script code: node-gyp rebuild
gyp info it worked if it ends with ok
gyp info using node-gyp@9.4.0
gyp info using node@20.9.0 | linux | x64
gyp info find Python using Python version 3.11.2 found at "/usr/bin/python3"
gyp info spawn /usr/bin/python3
gyp info spawn args [
gyp info spawn args '/usr/src/app/.yarn/unplugged/node-gyp-npm-9.4.0-ebf5f5573e/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'make',
gyp info spawn args '-I',
gyp info spawn args '/usr/src/app/.yarn/unplugged/aws-lambda-ric-npm-3.1.0-cdcf7fa443/node_modules/aws-lambda-ric/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/usr/src/app/.yarn/unplugged/node-gyp-npm-9.4.0-ebf5f5573e/node_modules/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/root/.cache/node-gyp/20.9.0/include/node/common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=/root/.cache/node-gyp/20.9.0',
gyp info spawn args '-Dnode_gyp_dir=/usr/src/app/.yarn/unplugged/node-gyp-npm-9.4.0-ebf5f5573e/node_modules/node-gyp',
gyp info spawn args '-Dnode_lib_file=/root/.cache/node-gyp/20.9.0/<(target_arch)/node.lib',
gyp info spawn args '-Dmodule_root_dir=/usr/src/app/.yarn/unplugged/aws-lambda-ric-npm-3.1.0-cdcf7fa443/node_modules/aws-lambda-ric',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'build',
gyp info spawn args '-Goutput_dir=.'
gyp info spawn args ]
/bin/sh: 1: deps/artifacts/bin/curl-config: not found
gyp: Call to 'deps/artifacts/bin/curl-config --static-libs' returned exit status 127 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/usr/src/app/.yarn/unplugged/node-gyp-npm-9.4.0-ebf5f5573e/node_modules/node-gyp/lib/configure.js:325:16)
gyp ERR! stack at ChildProcess.emit (node:events:514:28)
gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:294:12)
gyp ERR! System Linux 6.4.16-linuxkit
gyp ERR! command "/usr/local/bin/node" "/usr/src/app/.yarn/unplugged/node-gyp-npm-9.4.0-ebf5f5573e/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/src/app/.yarn/unplugged/aws-lambda-ric-npm-3.1.0-cdcf7fa443/node_modules/aws-lambda-ric
gyp ERR! node -v v20.9.0
gyp ERR! node-gyp -v v9.4.0
gyp ERR! not ok
- Ngôn ngữ chính
- TypeScript
- Star
- 224
- Fork
- 60
- Merge trung bình
- 26 phút
- Pull request đã merge (30 ngày)
- 2
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của aws/aws-lambda-nodejs-runtime-interface-client
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 20/100
aws/aws-lambda-nodejs-runtime-interface-client#198 · 3 bình luận · 6 reaction ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
aws/aws-lambda-nodejs-runtime-interface-client#195 · 12 reaction ·
-
bug
aws/aws-lambda-nodejs-runtime-interface-client#170 · 15 bình luận · 6 reaction · 1 người được giao ·
-
AWS Inspector findings for curl Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 38/100
aws/aws-lambda-nodejs-runtime-interface-client#159 · 2 reaction ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 42/100
aws/aws-lambda-nodejs-runtime-interface-client#145 · 1 bình luận · 6 reaction ·
Tất cả issue của aws/aws-lambda-nodejs-runtime-interface-client
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
safetrustcr/dApp-SafeTrust#426 ·
-
area:workflow bug ready-for-agent
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
fil-donadoni/tolaria#4409 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
Fission-AI/OpenSpec#1960 ·
-
Add dependabot Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
corsairdev/corsair#1764 ·