func icon indicating copy to clipboard operation
func copied to clipboard

no matching manifest for linux/arm64/v8

Open AnujanR opened this issue 11 months ago • 7 comments

Image

Hi, i'm getting this error when i try to run the function locally in my mac (M1 pro Apple Silicon). Can anyone help me with resolving this issue?

AnujanR avatar Jan 17 '25 00:01 AnujanR

@AnujanR as of now the buildpack strategy works mostly only with amd64. Exceptions are Java and Go, these should work also on arm64.

One option is to somehow enable rosetta in docker, I do not have personal experience but I heard that with rosetta it is possible to run amd64 images on M1. (cc @aslom)

Another option is to use "s2i" build strategy instead: func build --builder=s2i.

Yet another option is to employ "on cluster build" where image is build in the cluster (presumably amd64), func deploy --remote=1, but you have to install some tekton tasks to your cluster first.

matejvasek avatar Jan 17 '25 01:01 matejvasek

IMO most simple solution would be func build --builder=s2i but then the resulting image would be arm64, so it would run locally on your machine but it might not work in the cluster, if the cluster is amd64.

matejvasek avatar Jan 17 '25 01:01 matejvasek

Hi @matejvasek thanks for the reply,

I need my function to run on my remote cluster and not locally. Although the function builds with func build --builder=s2i it cannot be used to deploy to my cloud cluster due to architecture mismatch as you said. Is there any workaround to build the image to be supported to my linux machine in my cluster. I tried tekton, but seems no luck in tekton too.

But i'll keep trying anyways. Thanks

AnujanR avatar Jan 24 '25 15:01 AnujanR

Also i'm using digital ocean's kubernetes cluster for this task, if you can assist me with tekton pipelines, that would be great

Thanks

AnujanR avatar Jan 24 '25 15:01 AnujanR

@AnujanR you can look at https://github.com/knative/func/blob/main/hack/install-tekton.sh

When tekton is installed your could try:

func deploy -v --remote=1

matejvasek avatar Feb 03 '25 14:02 matejvasek

But maybe digital ocean has its own way https://www.digitalocean.com/community/developer-center/kubernetes-ci-cd-using-tekton-argo-cd-and-knative-serverless-applications#step-3-install-tekton I do not know.

matejvasek avatar Feb 03 '25 15:02 matejvasek

is there anything planned to support development of functions and local testing on arm based machines? I'm on a macbook with M1 using rust and I would like to test out knative out as a solution.

vabatta avatar Feb 07 '25 01:02 vabatta

Hi, unfortunately the remote build on Tekton does not work on amd64: kn func deploy --remote Running Pipeline Task: Fetching git repository with the function source code Running Pipeline Task: scaffold Error: function pipeline run has failed with message:

2025/05/01 21:24:44 Error executing command: fork/exec /scaffold: exec format error

The second Task fails. The "*-pack-git-pipeline-run-kp42b-scaffold-pod" runs "ghcr.io/knative/func-utils:v2" Maybe the Container image "ghcr.io/knative/func-utils:v2" used in the "scaffold" Task is not multiplatform ?.

Is it possible to compile and specify / override the image used in that Task?

jgnoguer avatar May 01 '25 21:05 jgnoguer

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 Jul 31 '25 01:07 github-actions[bot]