From 9a69d0b3865bc81f72bd686625e1ca57bdce57a1 Mon Sep 17 00:00:00 2001 From: Paolo Salvatori Date: Wed, 14 Oct 2026 15:22:13 +0200 Subject: [PATCH 1/5] Add a note to Web App with SQL Database sample on MS EULA --- samples/web-app-sql-database/dotnet/README.md | 30 +++++++++++++++++++ samples/web-app-sql-database/python/README.md | 30 +++++++++++++++++++ 2 files changed, 60 insertions(+) diff --git a/samples/web-app-sql-database/dotnet/README.md b/samples/web-app-sql-database/dotnet/README.md index f2b1616..86b8fd8 100644 --- a/samples/web-app-sql-database/dotnet/README.md +++ b/samples/web-app-sql-database/dotnet/README.md @@ -6,6 +6,36 @@ This sample demonstrates a ASP.NET Core Razor Pages single-page web application The application connects to Azure SQL using a dedicated SQL login (rather than the server admin), and the deployment scripts seed the `Activities` table with a handful of sample plans so the app shows data on first load. +> [!NOTE] +> Each logical server you create runs a Microsoft SQL Server container, so you must accept the [SQL Server End-User Licensing Agreement](https://go.microsoft.com/fwlink/?LinkId=746388) before the emulator provisions one. +> Start the emulator with `MSSQL_ACCEPT_EULA` set to `Y`: +> +> ```bash +> LOCALSTACK_MSSQL_ACCEPT_EULA=Y lstk start +> ``` +> +> Host variables prefixed with `LOCALSTACK_` are forwarded to the emulator, so the container receives `MSSQL_ACCEPT_EULA=Y`. +> +> To accept it once rather than on every start, add it to an environment profile in your `lstk` config: +> +> ```toml +> [[containers]] +> type = "azure" +> tag = "latest" +> port = "4566" +> env = ["mssql"] +> +> [env.mssql] +> MSSQL_ACCEPT_EULA = "Y" +> ``` +> +> A profile's values are injected into the container directly, so the `LOCALSTACK_` prefix is not used here. +> `lstk` reads the first `config.toml` it finds, starting with `./.lstk/config.toml` in the current directory and then `$HOME/.config/lstk/config.toml`. +> See [Config file search order](/azure/developer-tools/running-localstack/lstk/configuration/#config-file-search-order) for the full list and [Passing environment variables to the container](/azure/developer-tools/running-localstack/lstk/configuration/#passing-environment-variables-to-the-container) for how profiles work. +> +> If you start the emulator with the `docker` CLI or Docker Compose, set `MSSQL_ACCEPT_EULA=Y` directly in the container environment instead. +> Without it, `az sql server create` fails with `(EulaNotAccepted)`. + Before installing the sample, make sure to create an [Azure Kubernetes Service (AKS)](https://learn.microsoft.com/en-us/azure/aks/what-is-aks) cluster by using one of the following scripts: - [scripts/01-system-assigned-managed-identity.sh](../../../scripts/01-system-assigned-managed-identity.sh): creates the cluster using a system-assigned managed identity as its cluster identity. diff --git a/samples/web-app-sql-database/python/README.md b/samples/web-app-sql-database/python/README.md index 8927b34..0fb99e2 100644 --- a/samples/web-app-sql-database/python/README.md +++ b/samples/web-app-sql-database/python/README.md @@ -6,6 +6,36 @@ This sample demonstrates a Python Flask single-page web application called *Vaca The application connects to Azure SQL using a dedicated SQL login (rather than the server admin), and the deployment scripts seed the `Activities` table with a handful of sample plans so the app shows data on first load. +> [!NOTE] +> Each logical server you create runs a Microsoft SQL Server container, so you must accept the [SQL Server End-User Licensing Agreement](https://go.microsoft.com/fwlink/?LinkId=746388) before the emulator provisions one. +> Start the emulator with `MSSQL_ACCEPT_EULA` set to `Y`: +> +> ```bash +> LOCALSTACK_MSSQL_ACCEPT_EULA=Y lstk start +> ``` +> +> Host variables prefixed with `LOCALSTACK_` are forwarded to the emulator, so the container receives `MSSQL_ACCEPT_EULA=Y`. +> +> To accept it once rather than on every start, add it to an environment profile in your `lstk` config: +> +> ```toml +> [[containers]] +> type = "azure" +> tag = "latest" +> port = "4566" +> env = ["mssql"] +> +> [env.mssql] +> MSSQL_ACCEPT_EULA = "Y" +> ``` +> +> A profile's values are injected into the container directly, so the `LOCALSTACK_` prefix is not used here. +> `lstk` reads the first `config.toml` it finds, starting with `./.lstk/config.toml` in the current directory and then `$HOME/.config/lstk/config.toml`. +> See [Config file search order](/azure/developer-tools/running-localstack/lstk/configuration/#config-file-search-order) for the full list and [Passing environment variables to the container](/azure/developer-tools/running-localstack/lstk/configuration/#passing-environment-variables-to-the-container) for how profiles work. +> +> If you start the emulator with the `docker` CLI or Docker Compose, set `MSSQL_ACCEPT_EULA=Y` directly in the container environment instead. +> Without it, `az sql server create` fails with `(EulaNotAccepted)`. + Before installing the sample, make sure to create an [Azure Kubernetes Service (AKS)](https://learn.microsoft.com/en-us/azure/aks/what-is-aks) cluster by using one of the following scripts: - [scripts/01-system-assigned-managed-identity.sh](../../../scripts/01-system-assigned-managed-identity.sh): creates the cluster using a system-assigned managed identity as its cluster identity. From 2d44e632a06bcd1235a1d0700e6589b09f166f5a Mon Sep 17 00:00:00 2001 From: Paolo Salvatori Date: Wed, 14 Oct 2026 15:25:05 +0200 Subject: [PATCH 2/5] Add --type azure to lstk start command --- samples/web-app-sql-database/dotnet/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/web-app-sql-database/dotnet/README.md b/samples/web-app-sql-database/dotnet/README.md index 86b8fd8..48d7201 100644 --- a/samples/web-app-sql-database/dotnet/README.md +++ b/samples/web-app-sql-database/dotnet/README.md @@ -11,7 +11,7 @@ The application connects to Azure SQL using a dedicated SQL login (rather than t > Start the emulator with `MSSQL_ACCEPT_EULA` set to `Y`: > > ```bash -> LOCALSTACK_MSSQL_ACCEPT_EULA=Y lstk start +> LOCALSTACK_MSSQL_ACCEPT_EULA=Y lstk start --type azure > ``` > > Host variables prefixed with `LOCALSTACK_` are forwarded to the emulator, so the container receives `MSSQL_ACCEPT_EULA=Y`. From 9d1bdbfc9859b5f41eb2809f397df6ab30055725 Mon Sep 17 00:00:00 2001 From: Paolo Salvatori Date: Wed, 14 Oct 2026 15:48:54 +0200 Subject: [PATCH 3/5] Update README with emulator start instructions Clarified instructions for starting the emulator with EULA acceptance. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --- samples/web-app-sql-database/python/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/web-app-sql-database/python/README.md b/samples/web-app-sql-database/python/README.md index 0fb99e2..25f1aa6 100644 --- a/samples/web-app-sql-database/python/README.md +++ b/samples/web-app-sql-database/python/README.md @@ -11,7 +11,7 @@ The application connects to Azure SQL using a dedicated SQL login (rather than t > Start the emulator with `MSSQL_ACCEPT_EULA` set to `Y`: > > ```bash -> LOCALSTACK_MSSQL_ACCEPT_EULA=Y lstk start +> LOCALSTACK_MSSQL_ACCEPT_EULA=Y lstk start --type azure > ``` > > Host variables prefixed with `LOCALSTACK_` are forwarded to the emulator, so the container receives `MSSQL_ACCEPT_EULA=Y`. From 6750d20dc6944568a48c8c06fdd26672da0a410a Mon Sep 17 00:00:00 2001 From: Paolo Salvatori Date: Wed, 14 Oct 2026 15:49:08 +0200 Subject: [PATCH 4/5] Fix links and formatting in README.md Updated links in README.md to use HTTPS and corrected formatting. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --- samples/web-app-sql-database/dotnet/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/web-app-sql-database/dotnet/README.md b/samples/web-app-sql-database/dotnet/README.md index 48d7201..dd17493 100644 --- a/samples/web-app-sql-database/dotnet/README.md +++ b/samples/web-app-sql-database/dotnet/README.md @@ -31,7 +31,7 @@ The application connects to Azure SQL using a dedicated SQL login (rather than t > > A profile's values are injected into the container directly, so the `LOCALSTACK_` prefix is not used here. > `lstk` reads the first `config.toml` it finds, starting with `./.lstk/config.toml` in the current directory and then `$HOME/.config/lstk/config.toml`. -> See [Config file search order](/azure/developer-tools/running-localstack/lstk/configuration/#config-file-search-order) for the full list and [Passing environment variables to the container](/azure/developer-tools/running-localstack/lstk/configuration/#passing-environment-variables-to-the-container) for how profiles work. +> See [Config file search order](https://docs.localstack.cloud/azure/developer-tools/running-localstack/lstk/configuration/#config-file-search-order) for the full list and [Passing environment variables to the container](https://docs.localstack.cloud/azure/developer-tools/running-localstack/lstk/configuration/#passing-environment-variables-to-the-container) for how profiles work. > > If you start the emulator with the `docker` CLI or Docker Compose, set `MSSQL_ACCEPT_EULA=Y` directly in the container environment instead. > Without it, `az sql server create` fails with `(EulaNotAccepted)`. From 1f99b2a138d6482d545c673d25341fe05598340d Mon Sep 17 00:00:00 2001 From: Paolo Salvatori Date: Wed, 14 Oct 2026 15:49:18 +0200 Subject: [PATCH 5/5] Fix Markdown links and clarify environment variable usage Updated links in README to use proper Markdown syntax and added clarification on environment variable settings for the emulator. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --- samples/web-app-sql-database/python/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/web-app-sql-database/python/README.md b/samples/web-app-sql-database/python/README.md index 25f1aa6..e6ac54a 100644 --- a/samples/web-app-sql-database/python/README.md +++ b/samples/web-app-sql-database/python/README.md @@ -31,7 +31,7 @@ The application connects to Azure SQL using a dedicated SQL login (rather than t > > A profile's values are injected into the container directly, so the `LOCALSTACK_` prefix is not used here. > `lstk` reads the first `config.toml` it finds, starting with `./.lstk/config.toml` in the current directory and then `$HOME/.config/lstk/config.toml`. -> See [Config file search order](/azure/developer-tools/running-localstack/lstk/configuration/#config-file-search-order) for the full list and [Passing environment variables to the container](/azure/developer-tools/running-localstack/lstk/configuration/#passing-environment-variables-to-the-container) for how profiles work. +> See [Config file search order](https://docs.localstack.cloud/azure/developer-tools/running-localstack/lstk/configuration/#config-file-search-order) for the full list and [Passing environment variables to the container](https://docs.localstack.cloud/azure/developer-tools/running-localstack/lstk/configuration/#passing-environment-variables-to-the-container) for how profiles work. > > If you start the emulator with the `docker` CLI or Docker Compose, set `MSSQL_ACCEPT_EULA=Y` directly in the container environment instead. > Without it, `az sql server create` fails with `(EulaNotAccepted)`.