Skip to content

Commit cf3d755

Browse files
authored
Merge pull request #221129 from zhoufenqin/fenzho/build-service
feat: improve build-service doc
2 parents 8b675fa + e146ff4 commit cf3d755

18 files changed

+570
-318
lines changed

articles/spring-apps/.openpublishing.redirection.spring-apps.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@
1414
"source_path": "tutorial-managed-identities-mysql.md",
1515
"redirect_url": "/azure/developer/java/spring-framework/deploy-passwordless-spring-database-app",
1616
"redirect_document_id": false
17+
},
18+
{
19+
"source_path": "how-to-enterprise-deploy-non-java-apps.md",
20+
"redirect_url": "/azure/spring-apps/how-to-enterprise-deploy-polyglot-apps",
21+
"redirect_document_id": false
1722
}
1823
]
1924
}

articles/spring-apps/how-to-application-insights.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ az spring app-insights update \
281281

282282
This section applies to the Enterprise Tier only, and provides instructions that that supplement the previous section.
283283

284-
Azure Enterprise tier uses [Buildpack Bindings](./how-to-enterprise-build-service.md#buildpack-bindings) to integrate [Azure Application Insights](../azure-monitor/app/app-insights-overview.md) with the type `ApplicationInsights`.
284+
Azure Enterprise tier uses buildpack bindings to integrate [Azure Application Insights](../azure-monitor/app/app-insights-overview.md) with the type `ApplicationInsights`. For more information, see [How to configure APM integration and CA certificates](how-to-enterprise-configure-apm-intergration-and-ca-certificates.md).
285285

286286
To create an Application Insights buildpack binding, use the following command:
287287

articles/spring-apps/how-to-deploy-with-custom-container-image.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ If you deployed the instance to a VNet, make sure you allow the network traffic
189189

190190
### Install an APM into the image manually
191191

192-
The installation steps vary on different APMs and languages. The following steps are for New Relic with Java applications. You must modify the *Dockerfile* using the following steps:
192+
The installation steps vary on different application performance monitors (APMs) and languages. The following steps are for New Relic with Java applications. You must modify the *Dockerfile* using the following steps:
193193

194194
1. Download and install the agent file into the image by adding the following to the *Dockerfile*:
195195

articles/spring-apps/how-to-enterprise-build-service.md

Lines changed: 49 additions & 198 deletions
Large diffs are not rendered by default.
Lines changed: 266 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,266 @@
1+
---
2+
title: How to configure APM integration and CA certificates
3+
titleSuffix: Azure Spring Apps Enterprise tier
4+
description: How to configure APM integration and CA certificates
5+
author: karlerickson
6+
ms.author: fenzho
7+
ms.service: spring-apps
8+
ms.topic: how-to
9+
ms.date: 01/13/2023
10+
ms.custom: devx-track-java, devx-track-azurecli, event-tier1-build-2022
11+
---
12+
13+
# How to configure APM integration and CA certificates
14+
15+
> [!NOTE]
16+
> Azure Spring Apps is the new name for the Azure Spring Cloud service. Although the service has a new name, you'll see the old name in some places for a while as we work to update assets such as screenshots, videos, and diagrams.
17+
18+
**This article applies to:** ❌ Basic/Standard tier ✔️ Enterprise tier
19+
20+
This article shows you how to configure application performance monitor (APM) integration and certificate authority (CA) certificates in Azure Spring Apps Enterprise tier.
21+
22+
## Prerequisites
23+
24+
- An already provisioned Azure Spring Apps Enterprise tier instance. For more information, see [Quickstart: Build and deploy apps to Azure Spring Apps using the Enterprise tier](quickstart-deploy-apps-enterprise.md).
25+
26+
## Supported scenarios - APM and CA certificates integration
27+
28+
Azure Spring Apps Enterprise tier uses buildpack bindings to integrate with [Tanzu Partner Buildpacks](https://docs.pivotal.io/tanzu-buildpacks/partner-integrations/partner-integration-buildpacks.html) and other Cloud Native Buildpack like [ca-certificate buildpack](https://github.com/paketo-buildpacks/ca-certificates).
29+
30+
Currently, the following APM types and CA certificates are supported:
31+
32+
- [ApplicationInsights](#use-application-insights)
33+
- [Dynatrace](#use-dynatrace)
34+
- [AppDynamics](#use-appdynamics)
35+
- [NewRelic](#use-new-relic)
36+
- [ElasticAPM](#use-elasticapm)
37+
- [CA certificates](#use-ca-certificates)
38+
39+
CA Certificates are supported for all language family buildpacks, but not all supported APMs. The following table shows the binding types supported by Tanzu language family buildpacks.
40+
41+
| Buildpack | ApplicationInsights | NewRelic | AppDynamics | Dynatrace | ElasticAPM |
42+
|-------------------------------------------------------|---------------------|----------|-------------|-----------|------------|
43+
| Java ||||||
44+
| Dotnet ||||||
45+
| Go ||||||
46+
| Python ||||||
47+
| NodeJS ||||||
48+
| [WebServers](how-to-enterprise-deploy-static-file.md) ||||||
49+
50+
### Use Application Insights
51+
52+
The following languages are supported:
53+
54+
- Java
55+
56+
The following list shows the required environment variables:
57+
58+
- `connection-string`
59+
- `sampling-percentage`
60+
61+
Upper-case keys are allowed, and you can also replace `_` with `-`.
62+
63+
For other supported environment variables, see [Application Insights Overview](/azure/azure-monitor/app/app-insights-overview?tabs=net).
64+
65+
### Use Dynatrace
66+
67+
The following languages are supported:
68+
69+
- Java
70+
- .NET
71+
- Go
72+
- Node.js
73+
- WebServers
74+
75+
The following list shows the required environment variables:
76+
77+
- `api-url` or `environment-id` (used in build step)
78+
- `api-token` (used in build step)
79+
- `TENANT`
80+
- `TENANTTOKEN`
81+
- `CONNECTION_POINT`
82+
83+
For other supported environment variables, see [Dynatrace Environment Variables](https://www.dynatrace.com/support/help/shortlink/azure-spring#envvar).
84+
85+
### Use New Relic
86+
87+
The following languages are supported:
88+
89+
- Java
90+
- Node.js
91+
92+
The following list shows the required environment variables:
93+
94+
- `license_key`
95+
- `app_name`
96+
97+
For other supported environment variables, see [New Relic Environment Variables](https://docs.newrelic.com/docs/apm/agents/java-agent/configuration/java-agent-configuration-config-file/#Environment_Variables).
98+
99+
### Use ElasticAPM
100+
101+
The following languages are supported:
102+
103+
- Java
104+
- Node.js
105+
106+
The following list shows the required environment variables:
107+
108+
- `service_name`
109+
- `application_packages`
110+
- `server_url`
111+
112+
For other supported environment variables, see [Elastic Environment Variables](https://www.elastic.co/guide/en/apm/agent/java/master/configuration.html).
113+
114+
### Use AppDynamics
115+
116+
The following languages are supported:
117+
118+
- Java
119+
- Node.js
120+
121+
The following list shows the required environment variables:
122+
123+
- `agent_application_name`
124+
- `agent_tier_name`
125+
- `agent_node_name`
126+
- `agent_account_name`
127+
- `agent_account_access_key`
128+
- `controller_host_name`
129+
- `controller_ssl_enabled`
130+
- `controller_port`
131+
132+
For other supported environment variables, see [AppDynamics Environment Variables](https://docs.appdynamics.com/21.11/en/application-monitoring/install-app-server-agents/java-agent/monitor-azure-spring-cloud-with-java-agent#MonitorAzureSpringCloudwithJavaAgent-ConfigureUsingtheEnvironmentVariablesorSystemProperties).
133+
134+
### Use CA certificates
135+
136+
CA certificates use [ca-certificate buildpack](https://github.com/paketo-buildpacks/ca-certificates) to support providing CA certificates to the system trust store at build and runtime.
137+
138+
In Azure Spring Apps Enterprise tier, the CA certificates will use the **Public Key Certificates** tab on the **TLS/SSL settings** page in the Azure portal, as shown in the following screenshot:
139+
140+
:::image type="content" source="media/how-to-enterprise-build-service/public-key-certificates.png" alt-text="Screenshot of Azure portal showing the public key certificates in SSL/TLS setting page." lightbox="media/how-to-enterprise-build-service/public-key-certificates.png":::
141+
142+
You can configure the CA certificates on the **Edit binding** page. The `succeeded` certificates are shown in the **CA Certificates** list.
143+
144+
:::image type="content" source="media/how-to-enterprise-build-service/ca-certificates-buildpack-binding.png" alt-text="Screenshot of Azure portal showing edit CA Certificates buildpack binding." lightbox="media/how-to-enterprise-build-service/ca-certificates-buildpack-binding.png":::
145+
146+
## Manage APM integration and CA certificates in Azure Spring Apps
147+
148+
In the current context, one buildpack binding means either credential configuration against one APM type, or CA certificates configuration against the CA Certificates type. For APM integration, follow the earlier instructions configure the necessary environment variables or secrets for your APM.
149+
150+
To edit buildpack bindings for the builder, select **Edit**. After a builder is bound to the buildpack bindings, the buildpack bindings are enabled for an app deployed with the builder.
151+
152+
:::image type="content" source="media/how-to-enterprise-build-service/edit-binding.png" alt-text="Screenshot of Azure portal showing the Build Service page with the Edit binding link highlighted." lightbox="media/how-to-enterprise-build-service/edit-binding.png":::
153+
154+
> [!NOTE]
155+
> When configuring environment variables for APM bindings, use key names without a prefix. For example, do not use a `DT_` prefix for a Dynatrace binding or `APPLICATIONINSIGHTS_` for Application Insights. Tanzu APM buildpacks will transform the key name to the original environment variable name with a prefix.
156+
157+
You can manage buildpack bindings with the Azure portal or the Azure CLI.
158+
159+
### [Azure portal](#tab/azure-portal)
160+
161+
### View buildpack bindings using the Azure portal
162+
163+
Follow these steps to view the current buildpack bindings:
164+
165+
1. Open the [Azure portal](https://portal.azure.com/?AppPlatformExtension=entdf#home).
166+
1. Select **Build Service**.
167+
1. Select **Edit** under the **Bindings** column to view the bindings configured under a builder.
168+
169+
:::image type="content" source="media/how-to-enterprise-build-service/edit-binding.png" alt-text="Screenshot of Azure portal showing the Build Service page with the Edit binding link highlighted." lightbox="media/how-to-enterprise-build-service/edit-binding.png":::
170+
171+
:::image type="content" source="media/how-to-enterprise-build-service/show-service-binding.png" alt-text="Screenshot of Azure portal showing the Edit bindings for default builder pane.":::
172+
173+
### Create a buildpack binding
174+
175+
To create a buildpack binding, select **Unbound** on the **Edit Bindings** page, specify the binding properties, and then select **Save**.
176+
177+
### Unbind a buildpack binding
178+
179+
You can unbind a buildpack binding by using the **Unbind binding** command, or by editing the binding properties.
180+
181+
To use the **Unbind binding** command, select the **Bound** hyperlink, and then select **Unbind binding**.
182+
183+
:::image type="content" source="media/how-to-enterprise-build-service/unbind-binding-command.png" alt-text="Screenshot of Azure portal showing the Unbind binding command.":::
184+
185+
To unbind a buildpack binding by editing binding properties, select **Edit Binding**, and then select **Unbind**.
186+
187+
:::image type="content" source="media/how-to-enterprise-build-service/unbind-binding-properties.png" alt-text="Screenshot of Azure portal showing binding properties.":::
188+
189+
When you unbind a binding, the bind status changes from **Bound** to **Unbound**.
190+
191+
### [Azure CLI](#tab/azure-cli)
192+
193+
### View buildpack bindings using the Azure CLI
194+
195+
View the current buildpack bindings by using the following command:
196+
197+
```azurecli
198+
az spring build-service builder buildpack-binding list \
199+
--resource-group <your-resource-group-name> \
200+
--service <your-service-instance-name> \
201+
--builder-name <your-builder-name>
202+
```
203+
204+
### Create a binding
205+
206+
Use this command to change the binding from *Unbound* to *Bound* status:
207+
208+
```azurecli
209+
az spring build-service builder buildpack-binding create \
210+
--resource-group <your-resource-group-name> \
211+
--service <your-service-instance-name> \
212+
--name <your-buildpack-binding-name> \
213+
--builder-name <your-builder-name> \
214+
--type <your-binding-type> \
215+
--properties a=b c=d \
216+
--secrets e=f g=h
217+
```
218+
219+
For information on the `properties` and `secrets` parameters for your buildpack, see the [Supported Scenarios - APM and CA Certificates Integration](#supported-scenarios---apm-and-ca-certificates-integration) section.
220+
221+
### Show the details for a specific binding
222+
223+
You can view the details of a specific binding by using the following command:
224+
225+
```azurecli
226+
az spring build-service builder buildpack-binding show \
227+
--resource-group <your-resource-group-name> \
228+
--service <your-service-instance-name> \
229+
--name <your-buildpack-binding-name> \
230+
--builder-name <your-builder-name>
231+
```
232+
233+
### Edit the properties of a binding
234+
235+
You can change a binding's properties by using the following command:
236+
237+
```azurecli
238+
az spring build-service builder buildpack-binding set \
239+
--resource-group <your-resource-group-name> \
240+
--service <your-service-instance-name> \
241+
--name <your-buildpack-binding-name> \
242+
--builder-name <your-builder-name> \
243+
--type <your-binding-type> \
244+
--properties a=b c=d \
245+
--secrets e=f2 g=h
246+
```
247+
248+
For more information on the `properties` and `secrets` parameters for your buildpack, see the [Supported Scenarios - APM and CA Certificates Integration](#supported-scenarios---apm-and-ca-certificates-integration) section.
249+
250+
### Delete a binding
251+
252+
Use the following command to change the binding status from *Bound* to *Unbound*.
253+
254+
```azurecli
255+
az spring build-service builder buildpack-binding delete \
256+
--resource-group <your-resource-group-name> \
257+
--service <your-service-instance-name> \
258+
--name <your-buildpack-binding-name> \
259+
--builder-name <your-builder-name>
260+
```
261+
262+
---
263+
264+
## Next steps
265+
266+
- [Azure Spring Apps](index.yml)

0 commit comments

Comments
 (0)