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
Copy file name to clipboardExpand all lines: articles/spring-apps/how-to-remote-debugging-app-instance.md
+39-18Lines changed: 39 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -79,6 +79,45 @@ az spring app get-remote-debugging-config \
79
79
80
80
---
81
81
82
+
## Assign an Azure role
83
+
84
+
Before connecting to an app instance, you must be granted the role *Azure Spring Apps Remote Debugging Role*,which includes the `Microsoft.AppPlatform/Spring/apps/deployments/remotedebugging/action` data action permission.
85
+
86
+
You can assign an Azure role using the Azure portal or Azure CLI.
87
+
88
+
### [Azure portal](#tab/azure-portal)
89
+
90
+
Use the following steps to assign an Azure role using the Azure portal.
91
+
92
+
1. Open the [Azure portal](https://portal.azure.com).
93
+
1. Open your existing Azure Spring Apps service instance.
94
+
1. Select **Access Control (IAM)** from the left menu.
95
+
1. Select **Add** in the command bar, and then select **Add role assignment**.
96
+
97
+
:::image type="content" source="media/how-to-remote-debugging-app-instance/add-role-assignment.png" alt-text="Screenshot of the Access Control(IAM) page showing the Add role assignment command." lightbox="media/how-to-remote-debugging-app-instance/add-role-assignment.png":::
98
+
99
+
1. Search for **Azure Spring Apps Connect Role** in the list, and then select **Next**.
100
+
101
+
:::image type="content" source="media/how-to-remote-debugging-app-instance/remote-debugging-role.png" alt-text="Screenshot of the Add role assignment page showing the Azure Spring Apps remote debugging Role." lightbox="media/how-to-remote-debugging-app-instance/remote-debugging-role.png":::
102
+
103
+
1. Select **Select members**, and then search for your username.
104
+
105
+
1. Select **Review + assign**.
106
+
107
+
### [Azure CLI](#tab/azure-cli)
108
+
109
+
Use the following Azure CLI command to obtain the **Azure Spring Apps Remote Debugging Role** role, which includes the `Microsoft.AppPlatform/Spring/apps/deployments/remotedebugging/action` data action permission.
110
+
111
+
```azurecli
112
+
az role assignment create \
113
+
--role "Azure Spring Apps Remote Debugging Role" \
114
+
--scope "<service-instance-resource-id>" \
115
+
--assignee "<your-identity>"
116
+
```
117
+
118
+
---
119
+
120
+
82
121
## Debug an app instance remotely
83
122
84
123
You can debug an app instance remotely using the Azure Toolkit for IntelliJ or the Azure Spring Apps for VS Code extension.
@@ -105,15 +144,6 @@ Use the following steps to enable or disable remote debugging:
105
144
106
145
Use the following steps to attach debugger.
107
146
108
-
1. Use the following Azure CLI command to obtain the **Azure Spring Apps Remote Debugging Role** role, which includes the `Microsoft.AppPlatform/Spring/apps/deployments/remotedebugging/action` data action permission.
109
-
110
-
```azurecli
111
-
az role assignment create \
112
-
--role "Azure Spring Apps Remote Debugging Role" \
113
-
--scope "<service-instance-resource-id>" \
114
-
--assignee "<your-identity>"
115
-
```
116
-
117
147
1. Select an app instance, and then select **Attach Debugger**. IntelliJ connects to the app instance and starts remote debugging.
118
148
119
149
:::image type="content" source="media/how-to-remote-debugging-app-instance/intellij-remote-debugging-instance.png" alt-text="Screenshot showing the Attach Debugger option." lightbox="media/how-to-remote-debugging-app-instance/intellij-remote-debugging-instance.png":::
@@ -160,15 +190,6 @@ Use the following steps to enable or disable remote debugging:
160
190
161
191
Use the following steps to attach debugger.
162
192
163
-
1. Use the following Azure CLI command to obtain the **Azure Spring Apps Remote Debugging Role** role, which includes the `Microsoft.AppPlatform/Spring/apps/deployments/remotedebugging/action` data action permission.
164
-
165
-
```azurecli
166
-
az role assignment create \
167
-
--role "Azure Spring Apps Remote Debugging Role" \
168
-
--scope "<service-instance-resource-id>" \
169
-
--assignee "<your-identity>"
170
-
```
171
-
172
193
1. Select an app instance, and then select **Attach Debugger**. VS Code connects to the app instance and starts remote debugging.
173
194
174
195
:::image type="content" source="media/how-to-remote-debugging-app-instance/visual-studio-code-remote-debugging-instance.png" alt-text="Screenshot showing the Attach Debugger option." lightbox="media/how-to-remote-debugging-app-instance/visual-studio-code-remote-debugging-instance.png":::
0 commit comments