You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit fb5cdf7
Browse filesBrowse the repository at this point in the historyBrowse files
Every code deployment is built with Microsoft's Oryx build image, which is published for amd64 only and is a .NET app, and .NET does not support QEMU. On a Mac with Apple silicon, Docker Desktop emulates amd64 with QEMU unless Rosetta is turned on, and the build can then crash, as reported in #143.
- Add a note to the Prerequisites of the 22 sample READMEs whose deployment depends on amd64-only images: the code-deployed web apps (Oryx build and runtime images, and SQL Server for web-app-sql-database) and the Function Apps (Oryx build image).
- Rewrite the architecture section of the top-level README: Docker Desktop uses Rosetta only when its setting is on, and QEMU otherwise; add the missing url-shortener and eventhubs-eventgrid rows; servicebus/java runs its Spring Boot app on the host and needs no amd64-only image.
- run-samples.sh: correct the architecture comments the same way, and print a Rosetta note when it runs on a Mac with Apple silicon.
Claude-Session: https://claude.ai/code/session_01NGfV8ZhpdZCZfbmfwWd3Sw
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
|`function-app-*`| ✅ | ✅ | built from a multi-arch `python` / `node` / `dotnet` base |
87
-
|`api-management-function-app`| ✅ | ✅ | the API Management gateway runs inside the emulator; its Function App backend is built from the multi-arch `python` base |
86
+
|`function-app-*`| ✅ | ✅ | built from a multi-arch `python` / `node` / `dotnet` base; the build step runs on the `amd64`-only Oryx build image, and where it cannot run the emulator installs a Python app's dependencies natively |
87
+
|`api-management-function-app`| ✅ | ✅ | the API Management gateway runs inside the emulator; its Function App backend is built from the multi-arch `python` base, with the same build step |
88
+
|`eventhubs-eventgrid`| ✅ | not in the arm64 CI | a Python Function App, like `function-app-*`|
88
89
|`web-app-custom-image`| ✅ | ✅ | the image the sample builds itself |
89
90
|`aci-blob-storage`| ✅ | ✅ | the image the sample builds itself |
90
91
|`container-apps-blob-storage`| ✅ | ✅ | the image the sample builds itself |
|`servicebus/java`| ✅ | not in the arm64 CI | none: the Spring Boot app runs on your machine (`mvn spring-boot:run`) against the emulator's Service Bus |
93
+
|`web-app-*` (code deployment) | ✅ | emulated | the Oryx build image and `mcr.microsoft.com/oryx/<platform>`|
92
94
|`eventhubs`| ✅ | emulated | deploys a dashboard web app (Oryx, as above) |
**"emulated" does not mean broken.** The emulator never pins `--platform`, so on an `arm64` host
97
-
Docker pulls the `amd64` image and runs it under whatever emulation the runtime provides. Docker
98
-
Desktop on Apple Silicon does this via Rosetta, so these samples do work on a Mac — just more
99
-
slowly. They fail only on an `arm64` host with no emulation registered, such as GitHub's
100
-
`ubuntu-*-arm` runners, which is why CI schedules only the natively-supported samples on `arm64`.
95
+
|`url-shortener`| ✅ | emulated | deploys a web app (Oryx, as above) and a Python Function App |
96
+
|`web-app-sql-database`| ✅ | emulated |`mcr.microsoft.com/mssql/server`, and the Oryx images of its web app |
97
+
98
+
**"emulated" means `amd64` emulation, and how well the samples run depends on the emulator.** The emulator never pins `--platform`, so on an `arm64` host Docker pulls the `amd64` image and runs it under whatever emulation the runtime provides. Where none is registered, such as GitHub's `ubuntu-*-arm` runners, the image cannot start at all, which is why CI schedules only the natively-supported samples on `arm64`.
99
+
100
+
> [!NOTE]
101
+
> **Macs with Apple silicon: turn on Rosetta.** Docker Desktop emulates `amd64` with Rosetta only when **Use Rosetta for x86_64/amd64 emulation on Apple Silicon** is on (Settings, **General**, with the **Apple Virtualization framework** as the Virtual Machine Manager; Docker VMM has no Rosetta), and with QEMU otherwise.
102
+
> Every code deployment, Function Apps included, is built with Microsoft's Oryx build image, which is `amd64`-only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for `arm64`) and is a .NET app, and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md): under QEMU that build can crash ([#143](https://github.com/localstack/localstack-azure-samples/issues/143)).
103
+
> Microsoft [does not test or support SQL Server under emulation](https://learn.microsoft.com/azure/azure-sql/database/local-dev-experience-dev-containers) either.
104
+
> The README of every sample that depends on these images says so in its Prerequisites.
101
105
102
106
`run-samples.sh` warns when it runs one of these on an `arm64` host; set `SKIP_AMD64_ONLY=1` to skip
103
107
them instead. The authoritative list lives in `ARM64_SAMPLE_DIRS` in [run-samples.sh](./run-samples.sh);
Copy file name to clipboardExpand all lines: samples/api-management-function-app/python/README.md
+5Lines changed: 5 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -58,6 +58,11 @@ The life of a request: the client calls `GET /inventory/items` on the gateway wi
58
58
-[Bicep](https://learn.microsoft.com/en-us/azure/azure-resource-manager/bicep/install) (for the Bicep deployment)
59
59
- A LocalStack account with a valid `LOCALSTACK_AUTH_TOKEN` (see the [Auth Token guide](https://docs.localstack.cloud/getting-started/auth-token/))
60
60
61
+
> [!NOTE]
62
+
> **Macs with Apple silicon**: the function app runs natively on arm64, but the emulator builds each deployment with Microsoft's Oryx build image, which Microsoft publishes for amd64 only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for arm64).
63
+
> Docker Desktop runs that build under amd64 emulation: in Docker Desktop's settings, under **General**, select the **Apple Virtualization framework** as the Virtual Machine Manager and turn on **Use Rosetta for x86_64/amd64 emulation on Apple Silicon**.
64
+
> Under QEMU, which Docker Desktop uses otherwise (Rosetta off, or Docker VMM, which has no Rosetta), the build can crash, because Oryx is a .NET app and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md).
65
+
61
66
## Setup
62
67
63
68
Start the LocalStack Azure emulator and route the Azure CLI to it:
Copy file name to clipboardExpand all lines: samples/eventhubs-eventgrid/python/README.md
+5Lines changed: 5 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -99,6 +99,11 @@ whatever happened to be in the last batch.
99
99
> aborts and the trigger silently never fires. Starting the emulator with `DNS_ADDRESS=0`
100
100
> sidesteps it.
101
101
102
+
> [!NOTE]
103
+
> **Macs with Apple silicon**: the function app runs natively on arm64, but the emulator builds each deployment with Microsoft's Oryx build image, which Microsoft publishes for amd64 only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for arm64).
104
+
> Docker Desktop runs that build under amd64 emulation: in Docker Desktop's settings, under **General**, select the **Apple Virtualization framework** as the Virtual Machine Manager and turn on **Use Rosetta for x86_64/amd64 emulation on Apple Silicon**.
105
+
> Under QEMU, which Docker Desktop uses otherwise (Rosetta off, or Docker VMM, which has no Rosetta), the build can crash, because Oryx is a .NET app and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md).
Copy file name to clipboardExpand all lines: samples/eventhubs/python/README.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -104,6 +104,12 @@ schema registry.
104
104
-[Terraform](https://developer.hashicorp.com/terraform/downloads) or the Bicep CLI, for
105
105
the alternative deployments
106
106
107
+
> [!NOTE]
108
+
> **Macs with Apple silicon**: this sample's dashboard is a web app deployed from code. The emulator builds it with Microsoft's Oryx build image and runs it on an Oryx runtime image, and Microsoft publishes both for amd64 only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for arm64).
109
+
> On a Mac with Apple silicon they run only under Docker Desktop's amd64 emulation: in Docker Desktop's settings, under **General**, select the **Apple Virtualization framework** as the Virtual Machine Manager and turn on **Use Rosetta for x86_64/amd64 emulation on Apple Silicon**.
110
+
> Under QEMU, which Docker Desktop uses otherwise (Rosetta off, or Docker VMM, which has no Rosetta), the sample is not expected to work: Oryx is a .NET app, and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md).
111
+
> The sample does not run on an arm64 Linux host without amd64 emulation.
Copy file name to clipboardExpand all lines: samples/function-app-front-door/python/README.md
+5Lines changed: 5 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -69,6 +69,11 @@ The life of a request: the client calls `GET /catalog/1` on the endpoint → the
69
69
-[jq](https://jqlang.org/) and `zip`
70
70
- A LocalStack account with a valid `LOCALSTACK_AUTH_TOKEN` (see the [Auth Token guide](https://docs.localstack.cloud/getting-started/auth-token/))
71
71
72
+
> [!NOTE]
73
+
> **Macs with Apple silicon**: the function app runs natively on arm64, but the emulator builds each deployment with Microsoft's Oryx build image, which Microsoft publishes for amd64 only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for arm64).
74
+
> Docker Desktop runs that build under amd64 emulation: in Docker Desktop's settings, under **General**, select the **Apple Virtualization framework** as the Virtual Machine Manager and turn on **Use Rosetta for x86_64/amd64 emulation on Apple Silicon**.
75
+
> Under QEMU, which Docker Desktop uses otherwise (Rosetta off, or Docker VMM, which has no Rosetta), the build can crash, because Oryx is a .NET app and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md).
76
+
72
77
## Setup
73
78
74
79
Start LocalStack for Azure and point the Azure CLI at it:
Copy file name to clipboardExpand all lines: samples/function-app-managed-identity/python/README.md
+5Lines changed: 5 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -50,6 +50,11 @@ The LocalStack emulator emulates the following services, which are necessary at
50
50
-[Bicep extension](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-bicep), if you plan to install the sample via Bicep.
51
51
-[Terraform](https://developer.hashicorp.com/terraform/downloads), if you plan to install the sample via Terraform.
52
52
53
+
> [!NOTE]
54
+
> **Macs with Apple silicon**: the function app runs natively on arm64, but the emulator builds each deployment with Microsoft's Oryx build image, which Microsoft publishes for amd64 only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for arm64).
55
+
> Docker Desktop runs that build under amd64 emulation: in Docker Desktop's settings, under **General**, select the **Apple Virtualization framework** as the Virtual Machine Manager and turn on **Use Rosetta for x86_64/amd64 emulation on Apple Silicon**.
56
+
> Under QEMU, which Docker Desktop uses otherwise (Rosetta off, or Docker VMM, which has no Rosetta), the build can crash, because Oryx is a .NET app and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md).
57
+
53
58
## Deployment
54
59
55
60
Set up the Azure emulator using the LocalStack for Azure Docker image. Before starting, ensure you have a valid `LOCALSTACK_AUTH_TOKEN` to access the Azure emulator. Refer to the [Auth Token guide](https://docs.localstack.cloud/getting-started/auth-token/) to obtain your Auth Token and set it in the `LOCALSTACK_AUTH_TOKEN` environment variable. The Azure Docker image is available on the [LocalStack Docker Hub](https://hub.docker.com/r/localstack/localstack-azure). To pull the image, execute:
Copy file name to clipboardExpand all lines: samples/function-app-service-bus/dotnet/README.md
+5Lines changed: 5 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -54,6 +54,11 @@ The solution is composed of the following Azure resources:
54
54
-[Bicep extension](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-bicep), if you plan to install the sample via Bicep.
55
55
-[Terraform](https://developer.hashicorp.com/terraform/downloads), if you plan to install the sample via Terraform.
56
56
57
+
> [!NOTE]
58
+
> **Macs with Apple silicon**: the function app runs natively on arm64, but the emulator builds each deployment with Microsoft's Oryx build image, which Microsoft publishes for amd64 only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for arm64).
59
+
> Docker Desktop runs that build under amd64 emulation: in Docker Desktop's settings, under **General**, select the **Apple Virtualization framework** as the Virtual Machine Manager and turn on **Use Rosetta for x86_64/amd64 emulation on Apple Silicon**.
60
+
> Under QEMU, which Docker Desktop uses otherwise (Rosetta off, or Docker VMM, which has no Rosetta), the build can crash, because Oryx is a .NET app and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md).
61
+
57
62
## Deployment
58
63
59
64
Set up the Azure emulator using the LocalStack for Azure Docker image. Before starting, ensure you have a valid `LOCALSTACK_AUTH_TOKEN` to access the Azure emulator. Refer to the [Auth Token guide](https://docs.localstack.cloud/getting-started/auth-token/) to obtain your Auth Token and set it in the `LOCALSTACK_AUTH_TOKEN` environment variable. The Azure Docker image is available on the [LocalStack Docker Hub](https://hub.docker.com/r/localstack/localstack-azure). To pull the image, execute:
Copy file name to clipboardExpand all lines: samples/function-app-storage-http/dotnet/README.md
+5Lines changed: 5 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -134,6 +134,11 @@ The sample uses the following configurable settings in `local.settings.json`:
134
134
-[jq](https://jqlang.org/) is a JSON processor for scripting.
135
135
-[Azure Storage Explorer](https://learn.microsoft.com/en-us/azure/storage/storage-explorer/vs-azure-tools-storage-manage-with-storage-explorer) for viewing storage contents.
136
136
137
+
> [!NOTE]
138
+
> **Macs with Apple silicon**: the function app runs natively on arm64, but the emulator builds each deployment with Microsoft's Oryx build image, which Microsoft publishes for amd64 only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for arm64).
139
+
> Docker Desktop runs that build under amd64 emulation: in Docker Desktop's settings, under **General**, select the **Apple Virtualization framework** as the Virtual Machine Manager and turn on **Use Rosetta for x86_64/amd64 emulation on Apple Silicon**.
140
+
> Under QEMU, which Docker Desktop uses otherwise (Rosetta off, or Docker VMM, which has no Rosetta), the build can crash, because Oryx is a .NET app and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md).
141
+
137
142
## Deployment
138
143
139
144
1. You can set up the Azure emulator by utilizing LocalStack for Azure Docker image. Before starting, ensure you have a valid `LOCALSTACK_AUTH_TOKEN` to access the Azure emulator. Refer to the [Auth Token guide](https://docs.localstack.cloud/getting-started/auth-token/) to obtain your Auth Token and specify it in the `LOCALSTACK_AUTH_TOKEN` environment variable. The Azure Docker image is available on the [LocalStack Docker Hub](https://hub.docker.com/r/localstack/localstack-azure). To pull the Azure Docker image, execute the following command:
Copy file name to clipboardExpand all lines: samples/url-shortener/python/README.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -85,6 +85,12 @@ The flow of a single link: `POST /shorten` → Table Storage + Key Vault + Servi
85
85
-[Bicep](https://learn.microsoft.com/en-us/azure/azure-resource-manager/bicep/install) (for the Bicep deployment)
86
86
- A LocalStack account with a valid `LOCALSTACK_AUTH_TOKEN` (see the [Auth Token guide](https://docs.localstack.cloud/getting-started/auth-token/))
87
87
88
+
> [!NOTE]
89
+
> **Macs with Apple silicon**: this sample's web app is deployed from code. The emulator builds it with Microsoft's Oryx build image and runs it on an Oryx runtime image, and Microsoft publishes both for amd64 only ([microsoft/Oryx#2133](https://github.com/microsoft/Oryx/issues/2133) asks for arm64).
90
+
> On a Mac with Apple silicon they run only under Docker Desktop's amd64 emulation: in Docker Desktop's settings, under **General**, select the **Apple Virtualization framework** as the Virtual Machine Manager and turn on **Use Rosetta for x86_64/amd64 emulation on Apple Silicon**.
91
+
> Under QEMU, which Docker Desktop uses otherwise (Rosetta off, or Docker VMM, which has no Rosetta), the sample is not expected to work: Oryx is a .NET app, and [.NET does not support QEMU](https://github.com/dotnet/core/blob/main/release-notes/8.0/supported-os.md).
92
+
> The sample does not run on an arm64 Linux host without amd64 emulation.
93
+
88
94
## Setup
89
95
90
96
Start the LocalStack Azure emulator and route the Azure CLI to it:
0 commit comments