func icon indicating copy to clipboard operation
func copied to clipboard

Unable to build nodejs/typescript function AMD image on Mac ARM

Open jrangelramos opened this issue 1 year ago • 1 comments

I'm attempting to build an AMD64 function images for NodeJS and Typescript runtimes without success. Below the output of a build/deploy attempt

% uname -m -s
Darwin arm64
% ./func_darwin_arm64 deploy --builder s2i --platform linux/amd64 -v -p ./tsfunc
Building function image
STEP 1/9: FROM registry.access.redhat.com/ubi8/nodejs-20-minimal@sha256:f4d14adfd57bcc6b96aa348d98df657fb877dafde75cde6b330e279fadbe0184
Trying to pull registry.access.redhat.com/ubi8/nodejs-20-minimal@sha256:f4d14adfd57bcc6b96aa348d98df657fb877dafde75cde6b330e279fadbe0184...
Getting image source signatures
Checking if image destination supports signatures
Copying blob sha256:9d49001ad6c59e36fff8fa74763be0954414b6ad5333f7855bb70fa0d6e86cb6
Copying blob sha256:cbf022a26ad4243bcd827d5d18712530a7a1d6c322d51c9603c65014ece5de5c
Copying config sha256:61ae66094a8114f7b639908e1ceb0e09ba94248ceb51d42511b87d63db6ed344
Writing manifest to image destination
Storing signatures
WARNING: image platform (linux/amd64) does not match the expected platform (linux/arm64)
STEP 2/9: LABEL "io.k8s.display-name"="image-registry.openshift-image-registry.svc:5000/testarm/tsfunc:latest"       "io.openshift.s2i.build.image"="registry.access.redhat.com/ubi8/nodejs-20-minimal@sha256:f4d14adfd57bcc6b96aa348d98df657fb877dafde75cde6b330e279fadbe0184"       "io.openshift.s2i.build.source-location"="./tsfunc"       "io.openshift.s2i.scripts-url"="image:///usr/libexec/s2i"
--> Using cache 63b764022eca5a06479e44b7b47b41c4e86eced81c9208cdac55edf49ab47ee9
--> 63b764022eca
STEP 3/9: ENV BP_NODE_RUN_SCRIPTS="build"
--> Using cache 651b09668b72a28883abd51a86220e57d8d674bc79964ee1b368317fdcb91634
--> 651b09668b72
STEP 4/9: USER root
--> Using cache 866320e7c5f0b1d4328550e7c0fbdf3d33847a5f28748ee97f53899eacb08259
--> 866320e7c5f0
STEP 5/9: COPY upload/src /tmp/src
--> Using cache 33a67cfd2bcc28f83b326a3841bf050322ea41a71ae41cbdfe35430e828f9521
--> 33a67cfd2bcc
STEP 6/9: RUN chown -R 1001:0 /tmp/src
--> Using cache 2e2db034fcbf957063e73558c0ad2725f8526dcdecedef770d50abd85d30e517
--> 2e2db034fcbf
STEP 7/9: USER 1001
--> Using cache 6ea6d9e7cc8f47327be496c229a663b3d285000d29c7e3cf29b0869c4a95eeed
--> 6ea6d9e7cc8f
STEP 8/9: RUN /usr/libexec/s2i/assemble
---> Installing application source ...
---> Installing all dependencies
qemu-x86_64-static: QEMU internal SIGSEGV {code=MAPERR, addr=0x20}
/usr/libexec/s2i/assemble: line 113:    31 Segmentation fault      (core dumped) NODE_ENV=development npm install
Error: building at STEP "RUN /usr/libexec/s2i/assemble": while running runtime: exit status 139

Note: rosetta2 is installed

jrangelramos avatar May 27 '24 19:05 jrangelramos

This issue is stale because it has been open for 90 days with no activity. It will automatically close after 30 more days of inactivity. Reopen the issue with /reopen. Mark the issue as fresh by adding the comment /remove-lifecycle stale.

github-actions[bot] avatar Aug 26 '24 01:08 github-actions[bot]

This issue is stale because it has been open for 90 days with no activity. It will automatically close after 30 more days of inactivity. Reopen the issue with /reopen. Mark the issue as fresh by adding the comment /remove-lifecycle stale.

github-actions[bot] avatar May 31 '25 01:05 github-actions[bot]