microsoft / microsoft/Oryx

[buildpacks] build dotnet-amd64 on arm64 machine

Open
#2,157 0 comments 0 reactions 1 assignee View on GitHub

@waliMSFT is already working on this.

Since Sep 19, 2023.

buildpack enhancement
Dominant language
C#
Stars
881
Forks
195
Avg merge
20h 13m
Merged PRs (30d)
13

Description

Bug Report

Currently, pack doesn't support specific platform targeting. However, it should still be possible to produce an amd64 image on an arm64 machine.

Current behavior

On M1 Mac, with dotnet and pack installed:

  1. dotnet new web -o repro
  2. cd repro
  3. pack build --builder "mcr.microsoft.com/oryx/builder:debian-buster-20230830.1" myimg

currently fails (dotnet restore hangs / eventually fails).

This is likely due to dotnet not supporting QEMU emulation.

Solution context

In .NET 8 (introduced -a <ARCH> flag), there should be a path to allow this, which involves using --platform using a Multiplatform-tagged image, and specify -a <ARCH> (.NET 8) or -rid (.NET 7):

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.