Skip to content

Commit 6447993

Browse files
committed
add cli section and links
1 parent ec532a5 commit 6447993

File tree

2 files changed

+36
-8
lines changed

2 files changed

+36
-8
lines changed

articles/app-service/configure-sidecar.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Configure sidecars
33
description: Step-by-step guide to configuring sidecars, including adding built-in extensions.
44
ms.topic: how-to
5-
ms.date: 07/02/2025
5+
ms.date: 07/14/2025
66
ms.author: cephalin
77
author: cephalin
88
---
@@ -21,7 +21,9 @@ This article provides practical steps for enabling and configuring sidecars in y
2121

2222
## Enable sidecar support for Linux custom containers
2323

24-
For a custom container, you need to explicitly enable sidecar support. In the portal, you can make the selection in the [App Service create wizard](https://portal.azure.com/#view/WebsitesExtension/AppServiceWebAppCreateV3Blade). You can also enable it in the **Deployment Center** > **Containers** page of an existing application.
24+
For a custom container, you need to explicitly enable sidecar support. In the portal, you can make the selection in the [App Service create wizard](https://portal.azure.com/#view/WebsitesExtension/AppServiceWebAppCreateV3Blade). You can also enable it for an existing app in the **Deployment Center** > **Containers** page of an existing application, as shown in the following screenshot:
25+
26+
:::image type="content" source="media/configure-sidecar/enable-sidecar.png" alt-text="A screenshot showing a custom container app's container settings with the Start Update button highlighted.":::
2527

2628
With the Azure CLI, set `LinuxFxVersion` to `sitecontainers`. For example:
2729

@@ -75,6 +77,28 @@ Add the `Microsoft.Web/sites/sitecontainers` resource type to an app. To pull a
7577
7678
For more information, see [Microsoft.Web sites/sitecontainers](/azure/templates/microsoft.web/sites/sitecontainers).
7779

80+
## Create sidecars with Azure CLI
81+
82+
Create a sidecar-enabled app with [az webapp create](/cli/azure/webapp#az-webapp-create). For example:
83+
84+
```azurecli-interactive
85+
az webapp create --name <app-name> --resource-group <group-name> --sitecontainers-app
86+
```
87+
88+
Create a sidecar container with [az webapp sitecontainers create](/cli/azure/webapp/sitecontainers?view=azure-cli-latest#az-webapp-sitecontainers-create). For example:
89+
90+
```azurecli-interactive
91+
az webapp sitecontainers create --name <app-name> --resource-group <group-name> --container-name <container> --image <image> --target-port <port>
92+
```
93+
94+
Create a sidecar container with a JSON file:
95+
96+
```azurecli-interactive
97+
az webapp sitecontainers create --name <app-name> --resource-group <group-name> --sitecontainers-spec-file <file-path>
98+
```
99+
100+
For all sidecar commands, see [az webapp sitecontainers](/cli/azure/webapp/sitecontainers).
101+
78102
## Set environment variables
79103

80104
In a Linux app, all containers (main and sidecars) share environment variables. To override a specific variable for a sidecar, add it in the sidecar's configuration.

articles/app-service/overview-sidecar.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,18 @@
22
title: Sidecars overview
33
description: Learn what sidecars are, their benefits, and how they work in Azure App Service for Linux.
44
ms.topic: overview
5-
ms.date: 07/02/2025
5+
ms.date: 07/14/2025
66
ms.author: cephalin
77
author: cephalin
88
---
99

1010
# Sidecars in Azure App Service
1111

12-
In Linux App Service apps (built-in containers and custom containers), a sidecar is an auxiliary container that runs in the same environment as your main app container. Sidecars can provide supporting services (like telemetry, caching, or AI inference) and are managed as part of your App Service app.
12+
In Linux App Service apps (code-only apps and custom containers), a sidecar is an auxiliary container that runs in the same environment as your main app container. Sidecars can provide supporting services (like telemetry, caching, or AI inference) and are managed as part of your App Service app.
1313

1414
## Why use sidecars on App Service?
1515

16-
Sidecars enable you to add new capabilities, such as monitoring, caching, AI, or custom logic, without modifying your main application code (in built-in containers) or your main container (in custom containers). Benefits include:
16+
Sidecars enable you to add new capabilities, such as monitoring, caching, AI, or custom logic, without modifying your main application code (in code-only apps) or your main container (in custom containers). Benefits include:
1717

1818
- **Separation of concerns:** Add or update services independently of your main app.
1919
- **Extensibility:** Integrate prebuilt or custom extensions (e.g., OpenTelemetry, Redis, Datadog, Phi-3/4 AI models).
@@ -27,7 +27,7 @@ Sidecars enable you to add new capabilities, such as monitoring, caching, AI, or
2727
- **Lifecycle:** Sidecars start, stop, and scale together with the main app container. When your app scales out or in, all associated sidecar containers follow the same lifecycle automatically.
2828
- **Configuration:** Sidecars can be configured via the Azure Portal, ARM templates, or CLI. You specify the container image, environment variables, and other settings for each container. App settings are shared across all containers. You can also set container-specific environment variables.
2929
- **Volume mounts:** Each container can have its own volume mounts.
30-
- **Authentication:** Sidecars can pull images from public or private registries. Use managed identity or admin credentials for private registries.
30+
- **Authentication:** Sidecars can pull images from public or private registries, including Azure Container Registry. Use managed identity or admin credentials for private registries.
3131

3232
## Types of Sidecars
3333

@@ -40,8 +40,11 @@ Sidecars enable you to add new capabilities, such as monitoring, caching, AI, or
4040

4141
## Frequently Asked Questions
4242

43-
### Can I use private container registries?
44-
Yes. Configure authentication using managed identity or admin credentials.
43+
### Can I use sidecars in my existing Linux apps?
44+
45+
For existing Linux code-only apps (in built-in containers), see [Tutorial: Configure a sidecar container for a Linux app in Azure App Service](tutorial-sidecar.md).
46+
47+
For existing custom container apps, see [Enable sidecar support for Linux custom containers](configure-sidecar.md#enable-sidecar-support-for-linux-custom-containers).
4548

4649
### How do I monitor and troubleshoot sidecars?
4750
Use Azure Monitor, Log Analytics, and the Diagnose & Solve blade in the Azure Portal. Logs from all containers are available in the App Service log stream.
@@ -51,6 +54,7 @@ Persistent Azure storage is not supported for sidecars. App Service Environment
5154

5255
## More resources
5356

57+
- [Interactive guide: sidecars in Azure App Service](https://mslabs.cloudguides.com/guides/Modernize%20existing%20web%20apps%20with%20new%20capabilities%20using%20Sidecar%20patterns)
5458
- [Tutorial: Configure a sidecar container for a Linux app in Azure App Service](tutorial-sidecar.md)
5559
- [Tutorial: Configure a sidecar container for custom container in Azure App Service](tutorial-custom-container-sidecar.md)
5660
- [Configure Sidecars in Azure App Service](configure-sidecar.md)

0 commit comments

Comments
 (0)